Community
Participate
Working Groups
Version: 3.2.0 Build id: I20060215-0010 Looking at API for build participant, there doesn't seem to be a way for participants to create their own markers. Participants are creating their own categorizedProblem, which are persisted by the builder. Currently, problems are persisted as Java problem markers, i.e. the marker type specified on categorized problem is ignored. Now, if using the categorizedProblem#getMarkerType(), new issues arise. When incrementally building, the Java builder deletes old markers, and replaces them with fresh new ones. How does a builder participant achieve the same effect ? The current story holds as all markers being created are true Java problem markers, and thus the builder management is just fine. I believe this would also require the participant to tell about its managed marker types, for the Java builder to find out the markers to flush before creating new ones.
Also, the format of the marker generated is reusing the Java problem template, i.e. clients cannot add more attributes if they want. CategorizedProblem defines some minimal contract, and certainly current attributes are ok, but clients should be allowed to create more.
For M5, ensured that API side is in place. Implementation will honour these during M6. * Added API CategorizedProblem#getExtraMarkerAttributeNames() and getExtraMarkerAttributeValues() to allow to specify extra attributes in problem markers. * Added 'managedMarker' sequence on 'compilationParticipant' extension point to declare marker types that are persisted by the Java builder.
Changed JavaModelManager.CompilationParticipants to take the 'managedMarker' sequence into account. Also changed AbstractImageBuilder to create markers only if the corresponding categorized problem has a managed marker type. Finally changed JavaBuilder to delete all managed markers for a given resource. Updated APT plugin.xml and APT tests to reflect this change.
Verified for 3.2M6 using build I20060327-0010.