Quantcast

java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :

java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

Olivier Gaudin-2
Hello David,

What is your version of Sonar ? Which plugin and which version of the plugin ?

Olivier


On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :
java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
I tried to add Tech Debt plugin to my previous configuration with
Metrics Analysis plugin.
Because of this problem, I rolled back my conf to the previous
generated war, but I'm still stuck with this error.
Sonar version is 1.10.1
All plug in are up to date.

2009/8/22, Olivier Gaudin <[hidden email]>:

> Hello David,
>
> What is your version of Sonar ? Which plugin and which version of the plugin
> ?
>
> Olivier
>
>
> On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <[hidden email]> wrote:
>
>> I've just stopped Sonar in order to add a plug in in the external plugin
>> folder in my configuration.
>>
>> Now, everytime I try to launch the Hudson job related to quality analysis,
>> I've got this exception :
>>
>> java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
>> at java.lang.ClassLoader.defineClass1(Native Method)
>> at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
>> at
>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
>>
>>
>> at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
>> at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
>> at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
>> at java.security.AccessController.doPrivileged(Native Method)
>>
>>
>> at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>> at
>> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
>> at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
>>
>>
>> at
>> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>> at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>> at java.lang.Class.forName0(Native Method)
>>
>>
>> at java.lang.Class.forName(Class.java:247)
>> at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
>> at org.sonar.api.Plugins.<init>(Plugins.java:42)
>> at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
>>
>>
>> at org.sonar.batch.Batch.analyse(Batch.java:77)
>> at org.sonar.batch.Batch.start(Batch.java:54)
>> at org.sonar.batch.Batch.start(Batch.java:50)
>> at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
>> at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
>>
>>
>> at
>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
>> at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
>> at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
>>
>>
>> at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
>> at
>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
>>
>>
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
>>
>>
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
>>
>>
>> at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
>> at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
>> at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
>>
>>
>> at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>
>>
>> at java.lang.reflect.Method.invoke(Method.java:597)
>> at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>> at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>> at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>>
>>
>> at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
>> Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
>> at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>> at java.security.AccessController.doPrivileged(Native Method)
>>
>>
>> at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>> at
>> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
>> at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
>>
>>
>> at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
>> at
>> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
>> at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>
>>
>> at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>> ... 46 more
>>
>>
>>
>> Do you know why and how I can fix this ?
>>
>

--
Envoyé avec mon mobile

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

Olivier Gaudin-2
Can you send the complete log file ?

Olivier



On Sat, Aug 22, 2009 at 1:20 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I tried to add Tech Debt plugin to my previous configuration with
Metrics Analysis plugin.
Because of this problem, I rolled back my conf to the previous
generated war, but I'm still stuck with this error.
Sonar version is 1.10.1
All plug in are up to date.

2009/8/22, Olivier Gaudin <[hidden email]>:
> Hello David,
>
> What is your version of Sonar ? Which plugin and which version of the plugin
> ?
>
> Olivier
>
>
> On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
>
>> I've just stopped Sonar in order to add a plug in in the external plugin
>> folder in my configuration.
>>
>> Now, everytime I try to launch the Hudson job related to quality analysis,
>> I've got this exception :
>>
>> java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
>>      at java.lang.ClassLoader.defineClass1(Native Method)
>>      at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
>>      at
>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
>>
>>
>>      at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
>>      at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
>>      at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>
>>
>>      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
>>      at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
>>
>>
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>>      at java.lang.Class.forName0(Native Method)
>>
>>
>>      at java.lang.Class.forName(Class.java:247)
>>      at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
>>      at org.sonar.api.Plugins.<init>(Plugins.java:42)
>>      at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
>>
>>
>>      at org.sonar.batch.Batch.analyse(Batch.java:77)
>>      at org.sonar.batch.Batch.start(Batch.java:54)
>>      at org.sonar.batch.Batch.start(Batch.java:50)
>>      at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
>>      at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
>>
>>
>>      at
>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
>>      at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
>>      at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
>>
>>
>>      at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
>>      at
>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
>>
>>
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
>>
>>
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
>>
>>
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
>>      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
>>      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
>>
>>
>>      at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
>>      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>      at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>      at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>
>>
>>      at java.lang.reflect.Method.invoke(Method.java:597)
>>      at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>>      at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>>      at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>>
>>
>>      at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
>> Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
>>      at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>
>>
>>      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
>>      at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
>>
>>
>>      at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>
>>
>>      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>>      ... 46 more
>>
>>
>>
>> Do you know why and how I can fix this ?
>>
>

--
Envoyé avec mon mobile

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
Hello Olivier,

Here it is.

I tried to delete the maven sonar plugin from the maven local repository, without success.

David

On Mon, Aug 24, 2009 at 10:14 AM, Olivier Gaudin <[hidden email]> wrote:
Can you send the complete log file ?

Olivier



On Sat, Aug 22, 2009 at 1:20 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I tried to add Tech Debt plugin to my previous configuration with
Metrics Analysis plugin.
Because of this problem, I rolled back my conf to the previous
generated war, but I'm still stuck with this error.
Sonar version is 1.10.1
All plug in are up to date.

2009/8/22, Olivier Gaudin <[hidden email]>:
> Hello David,
>
> What is your version of Sonar ? Which plugin and which version of the plugin
> ?
>
> Olivier
>
>
> On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
>
>> I've just stopped Sonar in order to add a plug in in the external plugin
>> folder in my configuration.
>>
>> Now, everytime I try to launch the Hudson job related to quality analysis,
>> I've got this exception :
>>
>> java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
>>      at java.lang.ClassLoader.defineClass1(Native Method)
>>      at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
>>      at
>> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
>>
>>
>>      at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
>>      at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
>>      at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>
>>
>>      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
>>      at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
>>
>>
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>>      at java.lang.Class.forName0(Native Method)
>>
>>
>>      at java.lang.Class.forName(Class.java:247)
>>      at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
>>      at org.sonar.api.Plugins.<init>(Plugins.java:42)
>>      at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
>>
>>
>>      at org.sonar.batch.Batch.analyse(Batch.java:77)
>>      at org.sonar.batch.Batch.start(Batch.java:54)
>>      at org.sonar.batch.Batch.start(Batch.java:50)
>>      at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
>>      at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
>>
>>
>>      at
>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
>>      at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
>>      at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
>>
>>
>>      at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
>>      at
>> org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
>>
>>
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
>>
>>
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
>>
>>
>>      at
>> org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
>>      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
>>      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
>>
>>
>>      at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
>>      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>      at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>>      at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>>
>>
>>      at java.lang.reflect.Method.invoke(Method.java:597)
>>      at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>>      at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>>      at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>>
>>
>>      at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
>> Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
>>      at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>
>>
>>      at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
>>      at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
>>
>>
>>      at
>> org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
>>      at
>> org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
>>      at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
>>
>>
>>      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
>>      ... 46 more
>>
>>
>>
>> Do you know why and how I can fix this ?
>>
>

--
Envoyé avec mon mobile

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

   http://xircles.codehaus.org/manage_email





---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email

sonar.job.log (58K) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
In reply to this post by David MARTIN-10
It appear <span class="item-link" onclick="window.location.href=&#39;http://maven.dev-factory.nffr:80/artifactory/repo1-cache/org/codehaus/sonar/sonar-plugin-api/1.10.1/sonar-plugin-api-1.10.1.jar&#39;;return false;">sonar-plugin-api-1.10.1.jar has a different structure from the previous version <span class="item-link" onclick="window.location.href=&#39;http://maven.dev-factory.nffr:80/artifactory/repo1-cache/org/codehaus/sonar/sonar-plugin-api/1.10.1/sonar-plugin-api-1.10.1.jar&#39;;return false;">sonar-plugin-api-1.9.2.jar :
- Plugin class isn't stored in the same package :
org/sonar/plugins/api/Plugin is now org/sonar/api/Plugin

It may be the origin of this problem.

David

On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :
java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
I tried many different things, like :
- cleaning our Maven proxy
- cleaning the local maven repository
- executing the plug in from the command line...
- rebuilding the war without any plug in...

And I always have the same error. => I'm stuck with a broken Sonar installation.

If you have any idea...

David

On Mon, Aug 24, 2009 at 11:04 AM, David MARTIN <dmartin.pro@gmail.com> wrote:
It appear sonar-plugin-api-1.10.1.jar has a different structure from the previous version sonar-plugin-api-1.9.2.jar :
- Plugin class isn't stored in the same package :
org/sonar/plugins/api/Plugin is now org/sonar/api/Plugin

It may be the origin of this problem.

David

On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :
java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
In reply to this post by David MARTIN-10
I'm still trying to understand...

Here is what I noticed a few minutes ago, in the webapp/sonar/deploy folder :

every folder under /webapps/sonar/deploy/maven/org/codehaus/sonar/runtime/rules-extensions contain emma-0.2 !

I don't know what they are supposed to contain, but there is also some old dependencies here, like mysql-connector-java-5.0.8 which was updated in Sonar 1.10(.1) to 5.1.6 (this one is present in runtime/jdbc-driver)

What's going on with that ?

I know Emma-0.2 depends on the Plugin class, stored in the org/sonar/plugins/api/ package (I've decompiled it). That may be the reason of my error. But why did emma-0.2 appear in this folder ?

David

On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :
java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

Olivier Gaudin-2
David,

Can you have a look in $SONAR_HOME/extensions/rules and sub-directories to see if you have emma-0.2 ?

Further more Emma-0.2 is not compatible with Sonar 1.10.

Olivier



On Mon, Aug 24, 2009 at 3:42 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I'm still trying to understand...

Here is what I noticed a few minutes ago, in the webapp/sonar/deploy folder :

every folder under /webapps/sonar/deploy/maven/org/codehaus/sonar/runtime/rules-extensions contain emma-0.2 !

I don't know what they are supposed to contain, but there is also some old dependencies here, like mysql-connector-java-5.0.8 which was updated in Sonar 1.10(.1) to 5.1.6 (this one is present in runtime/jdbc-driver)

What's going on with that ?

I know Emma-0.2 depends on the Plugin class, stored in the org/sonar/plugins/api/ package (I've decompiled it). That may be the reason of my error. But why did emma-0.2 appear in this folder ?

David

On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :
java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Re: java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin

David MARTIN-10
I do not have any emma-0.2.jar in $SONAR_HOME/extensions/rules or any sub directory
BUT
I had an emma-0.2.jar jar in $SONAR_HOME/extensions/
And that was the problem !

Sonar seems to scan $SONAR_HOME/extensions/ root and every sub folder, not only predefined ones. That's why emma-0.2.jar was detected and considered.

Thank you for this clue !

Sonar is now up and running !

David

On Mon, Aug 24, 2009 at 4:05 PM, Olivier Gaudin <[hidden email]> wrote:
David,

Can you have a look in $SONAR_HOME/extensions/rules and sub-directories to see if you have emma-0.2 ?

Further more Emma-0.2 is not compatible with Sonar 1.10.

Olivier




On Mon, Aug 24, 2009 at 3:42 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I'm still trying to understand...

Here is what I noticed a few minutes ago, in the webapp/sonar/deploy folder :

every folder under /webapps/sonar/deploy/maven/org/codehaus/sonar/runtime/rules-extensions contain emma-0.2 !

I don't know what they are supposed to contain, but there is also some old dependencies here, like mysql-connector-java-5.0.8 which was updated in Sonar 1.10(.1) to 5.1.6 (this one is present in runtime/jdbc-driver)

What's going on with that ?

I know Emma-0.2 depends on the Plugin class, stored in the org/sonar/plugins/api/ package (I've decompiled it). That may be the reason of my error. But why did emma-0.2 appear in this folder ?

David

On Fri, Aug 21, 2009 at 6:15 PM, David MARTIN <dmartin.pro@gmail.com> wrote:
I've just stopped Sonar in order to add a plug in in the external plugin folder in my configuration.

Now, everytime I try to launch the Hudson job related to quality analysis, I've got this exception :
java.lang.NoClassDefFoundError: org/sonar/plugins/api/Plugin
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at org.sonar.api.Plugins.introspectPlugins(Plugins.java:60)
at org.sonar.api.Plugins.<init>(Plugins.java:42)
at org.sonar.batch.BatchContext.startComponents(BatchContext.java:56)
at org.sonar.batch.Batch.analyse(Batch.java:77)
at org.sonar.batch.Batch.start(Batch.java:54)
at org.sonar.batch.Batch.start(Batch.java:50)
at org.sonar.batch.BatchMojo.executeBatch(BatchMojo.java:153)
at org.sonar.batch.BatchMojo.execute(BatchMojo.java:145)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.codehaus.mojo.sonar.Bootstraper.executeMojo(Bootstraper.java:82)
at org.codehaus.mojo.sonar.Bootstraper.start(Bootstraper.java:65)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:117)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:513)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:483)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:228)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:301)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.sonar.plugins.api.Plugin
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 46 more


Do you know why and how I can fix this ?



Loading...