Details
-
Type:
Improvement
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.9.2
-
Fix Version/s: 1.12
-
Component/s: Maven Plugin
-
Labels:None
-
Number of attachments :
Description
When a NoClassDefFoundError is thrown somewhere inside the Sonar Maven plugin, the following error message is logged and there is no way to know which class can't be found. This bug is due to PICO-363.
Caused by: java.lang.ClassCastException: java.lang.NoClassDefFoundError cannot b
e cast to java.lang.Exception
at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(
ReflectionLifecycleStrategy.java:115)
at org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(Reflect
ionLifecycleStrategy.java:89)
at org.picocontainer.adapters.InstanceAdapter.start(InstanceAdapter.java
:113)
at org.picocontainer.adapters.InstanceAdapter.start(InstanceAdapter.java
:91)
at org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoConta
iner.java:882)
at org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.jav
a:630)
at org.sonar.mojo.InternalMojo.createMainContainer(InternalMojo.java:192
)
at org.sonar.mojo.InternalMojo.execute(InternalMojo.java:154)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi
nManager.java:483)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
... 20 more
Attachments
Issue Links
| This issue is duplicated by: | ||||
| SONAR-1166 | java.lang.NoClassDefFoundError cannot be cast to java.lang.Exception |
|
|
|
| This issue depends upon: | ||||
| PICO-363 | Container startup bug when a component throws a InvocationTargetException |
|
|
|
there is a pico patch to get a better stacktrace: http://www.nabble.com/Embedded-error%3A-java.lang.NoClassDefFoundError-cannot-be-cast-to--java.lang.Exception-%28executing-mvn-sonar%3Asonar%29-td24639599.html#a25272996