|
View:
New views
15 Messages
—
Rating Filter:
Alert me
|
|
|
Problem with sonar-maven-plugin-1.8Hello;
I'm trying to get Sonar 1.8 up and running on a private intranet. I've got the web-app deployed, the database created, Nexus all configured, and am trying to get the sonar-maven-plugin working. But I'm getting the following error during the process: mvn clean install org.codehaus.sonar:sonar-maven-plugin:1.8:sonar BUILD ERROR Can not execute Sonar Embedded error: Unable to find the mojo 'org.codehaus.sonar.runtime:sonar-core-maven-plugin:20090609145257:internal' in the plugin 'org.codehaus.sonar.runtime:sonar-core-maven-plugin. When I navigate to the repo in Nexus, the sonar-core-maven-plugin is there, both the pom and the jar file. I suspect the problem is the 'internal' part of the plugin descriptor, but not sure how to get rid of this. We're using JDK 1.5.0_16, Maven 2.0.9, Nexus 1.3.4. It's downloading other plugins, because I see earlier in the session messages like Downloading: http:......./org/codehaus/sonar/runtime/jdbc-driver/mysql-connector-java-5.0.8/....pom No, I can't post the full output of the command, and no, I can't go up to a new version. Any help would be appreciated. Bob Yetman |
|
|
Re: Problem with sonar-maven-plugin-1.8Hello Bob,
It would be easier with the full trace, but anyway... Are you running 2 instances of Sonar at the same time ? Olivier On Wed, Jun 17, 2009 at 1:02 PM, Bob Yetman <bobyetman@...> wrote:
|
|
|
Re: Problem with sonar-maven-plugin-1.8Hello Bob,
Could you at least provide your maven mirror configuration defined in the settings.xml file ? thanks Freddy On Wed, Jun 17, 2009 at 2:09 PM, Olivier Gaudin <gaudol@...> wrote: Hello Bob, |
|
|
Re: Problem with sonar-maven-plugin-1.8To answer both questions, no I'm not running 2 instances of sonar at the same time.
from settings.xml: <mirrors> <mirror> <id>Nexus</id> <name>internal nexus</name> <url>http://........nexus/content/groups/public</url> <mirrorOf>!met2vendor,*</mirrorOf> </mirror> </mirrors> met2vendor is another internal nexus we use....
|
|
|
Re: Problem with sonar-maven-plugin-1.8Bob,
Could you try to restart the sonar web server ? Doing that will force the sonar maven plugin and so nexus to upload a fresh copy of all Sonar artifacts. Indeed, I suspect one jar to be corrupted.
Hope it helps Freddy On Wed, Jun 17, 2009 at 4:01 PM, Bob Yetman <bobyetman@...> wrote:
|
|
|
Re: Problem with sonar-maven-plugin-1.8Good morning Freddy;
I tried restarting the app server (tomcat) that the Sonar web app is deployed in, then went in and expired the Nexus cache and forced a re-index, and still get the same error. What's interesting though is that the datetime stamp in the error has changed to today. The jar & the pom exist in my local repo, so maven is getting them from nexus. (More of the log manually typed in, I wish I could cut and paste, but can't, machine's on a private intranet). ..... Downloading: http://mymachine:8082/nexus/content/groups/public/org/codehaus/sonar/sonar-plugin-api-1.8/sonar-plugin-api-1.8.pom ------------------------------------------------------------------------------------------------------ this realm = app0.child-container[org.codehaus.sonar.runtime:sonar-core-maven-plugin] urls[0] = file://home/myhome/.m2/repository/org/codehaus/sonar/runtime/sonar-core-maven-plugin/20090618065912/sonar-core-maven-plugin-20090618065912.jar urls[1]...... urls[21]..... Number of imports: 6 import org.codehaus.classwords.Entry@4891bb28 (5 more times with different entry numbers) this realm = plexus.core urls[0] = file://home/myhome/apache-maven-2.0.9/lib/maven-2.0.9-uber.jar Number of imports: 6 import org.codehaus.classwords.Entry@4891bb28 (5 more times with different entry numbers) ---------------------------------------------------------------------------------- [INFO]--------------------------------------------- [ERROR] BUILD ERROR [INFO]---------------------------------------------------------------------------- [INFO] Can not execute Sonar Embedded error: Unable to find the mojo 'org.codehaus.sonar.runtime:sonar-core-maven-plugin:20090618065912:internal' in the plugin 'org.codehaus.sonar.runtime:sonar-core-maven-plugin' org/apache/commons/configuration/Configuration [INFO]-------------------------------------------------------
|
|
|
Re: Problem with sonar-maven-plugin-1.8Hello Bob, can you try to add -U to the command ?
Olivier On Thu, Jun 18, 2009 at 1:40 PM, Bob Yetman <bobyetman@...> wrote:
|
|
|
Re: Problem with sonar-maven-plugin-1.8No change, still the same error message as before.
|
|
|
Re: Problem with sonar-maven-plugin-1.8Ok Bob, I've exactly reproduced your issue. The jar commons-configuration-1.5.jar is corrupted in your local maven repository :
commons-configurations/commons-configurations/1.5/commons-configuration-1.5.jar
Hope it helps
Freddy
On Mon, Jun 22, 2009 at 1:04 PM, Bob Yetman <bobyetman@...> wrote:
|
|
|
Re: Problem with sonar-maven-plugin-1.8Hmm, I've cleaned out my local repo before doing the install (for other reasons) and still
get this error, I'll have to check the in-house/remote repo tomorrow at work.
|
|
|
Re: Problem with sonar-maven-plugin-1.8Okay, I cleaned out my local (disk) repo again, reran the command, and commons-collection is
never even downloaded. So why is it not in the dependency list somewhere and being downloaded? I ran mvn with -X (probably should have done this earlier), and get the following: ..... Caused by: org.apache.maven.plugin.MojoExecutionException: Can not execute Sonar (stack trace left out) Caused by: org.apache.maven.plugin.PluginManagerException: Unable to find the mojo 'org.codehaus.sonar.runtime:sonar-core-maven-plugin-20090618065912:internal' in the plugin 'org.codehaus.sonar.runtime:sonar-core-maven-plugin' (stack trace left out) Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Unable to lookup component 'org.apache.maven.plugin.Mojoorg.codehaus.sonar.runtime:sonar-core-maven-plugin:20090618065912:internal', it could not be created (stack trace left out) Caused by: org.codehaus.plexus.component.factory.ComponentInstantiationException: Could not instanciate component: role: 'null', implementation: 'org.sonar.mojo.InternalMojo' (stack trace left out) Cause by: java.lang.NoClassDefFoundError: org/apache/commons/configuration/Configuration at java.lang.Class.getDeclaredConstructors0(Native Method) .... at java.lang.Class.newInstance(Class.java:303) at org.codehaus.plexus.component.factory.java.JavaComponentFactory.newInstance(JavaComponentFactory.java:44) ... 28 more
|
|
|
Re: Problem with sonar-maven-plugin-1.8Hello Bob,
Are you talking about commons-colection or commons-configuration ? From the trace you send, the problem is due to corruption of commons-configuration in your local and / or remote repository. You should remove it in both places. Olivier On Tue, Jun 23, 2009 at 1:40 PM, Bob Yetman <bobyetman@...> wrote:
|
|
|
Re: Problem with sonar-maven-plugin-1.8Oops, mistype on my part, it is commons-configuration. I totally deleted my local repo, and it's
never getting downloaded from my remote repo, so how could it be corrupted?
|
|
|
Re: Problem with sonar-maven-plugin-1.8Bob,
Sonar definitely depends on commons-configuration version 1.5. All our Maven modules use the following pom.xml file as parent : Moreover, your stacktrace is very explicit : Cause by: java.lang.NoClassDefFoundError: >> org/apache/commons/configuration/Configuration The only remaining question is "Why this explicit maven dependency is not downloaded ?"
Do you have any dependencies policy defined somewhere ? Thanks Freddy
On Tue, Jun 23, 2009 at 11:25 PM, Bob Yetman <bobyetman@...> wrote:
|
|
|
Re: Problem with sonar-maven-plugin-1.8Okay, I've solved the problem. When the security folks where I worked moved the sonar software from
the Internet to our intranet, they didn't bring the sonar-1.8.pom/sonar-commons-1.8.pom/sonar-maven-plugin-1.8.pom in-house, and without those, the dependencies weren't being satisfied correctly. After manually typing them in, it's now getting further, just have to get all the typos out of the files. Darn security....... Thanks for all the help tracking this down.
|
| Free embeddable forum powered by Nabble | Forum Help |