jbosstools/jbosstools-webservices — pull request #93 by xcoulon (2013-10-10 08:17:46+00:00)
Title: JBIDE-15428 - No JAX-RS problems when importing a project that contains HTTPMethod annotation without @Target and @Retention

Added accepted change event on a project: RESOLVED_CLASSPATH. This event is triggered when m2e adds the dependencies as libraries to the
project. In that case, a metamodel build should be triggered as it may resolve some compilation problems.

Move the call the JaxrsMetamodel#setBuildStatus() to finally{} blocks of JaxrsMetamodel#processXXX() methods

Adjusted some javadoc, log messages and catch() blocks (avoiding to catch Exception or Throwable)

Also, added a few synchronized() blocks to avoid concurrent access to the metamodel by different threads, for example if an async build
is still running and the validation is started. This avoids the following type of error:

{code}
!ENTRY org.jboss.tools.common 4 0 2013-10-09 18:17:54.307
!MESSAGE
!STACK 0
org.jboss.tools.common.validation.JBTValidationException
at org.jboss.tools.common.validation.ValidatorManager.validateInJob(ValidatorManager.java:101)
at org.eclipse.wst.validation.internal.operations.ValidatorJob.run(ValidatorJob.java:78)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)
Caused by: java.util.ConcurrentModificationException
at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793)
at java.util.HashMap$ValueIterator.next(HashMap.java:822)
at org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.JaxrsMetamodelValidator.validateAll(JaxrsMetamodelValidator.java:268)
at org.jboss.tools.ws.jaxrs.core.internal.metamodel.validation.JaxrsMetamodelValidator.validate(JaxrsMetamodelValidator.java:153)
at org.jboss.tools.common.validation.ValidatorManager.validate(ValidatorManager.java:117)
at org.jboss.tools.common.validation.ValidatorManager.validateInJob(ValidatorManager.java:81)
... 2 more
{code}