SonarQube 7.0.0.36138 does not support maven 3

3,440 views
Skip to first unread message

ghst...@gmail.com

unread,
Mar 6, 2018, 2:16:44 AM3/6/18
to SonarQube
I've been scratching my head over this for the past 10+ hours. My google-fu apparently is not sufficient.
I have found numerous references to things like this, but they are all 5+ year old posts or older.
Here is the appropriate part of my jenkins build log:
[INFO] 
[INFO] --- sonar-maven-plugin:2.5:sonar (default-cli) @ cad-console-root ---
[INFO] SonarQube version: 7.0.0.36138
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] 
[INFO] API Server ......................................... FAILURE [  1.102 s]
[INFO] cad-console-persistence ............................ SKIPPED
[INFO] cad-console-rest-services-app ...................... SKIPPED
[INFO] map-async-reports Job .............................. SKIPPED
[INFO] map-async-reports-app Maven Webapp ................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.437 s
[INFO] Finished at: 2018-03-05T22:34:54-08:00
[INFO] Final Memory: 16M/220M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.5:sonar (default-cli) on project cad-console-root: SonarQube 7.0.0.36138 does not support Maven 3 -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.5:sonar (default-cli) on project cad-console-root: SonarQube 7.0.0.36138 does not support Maven 3
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
	at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)
	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:483)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.MojoExecutionException: SonarQube 7.0.0.36138 does not support Maven 3
	at org.codehaus.mojo.sonar.SonarMojo.checkVersionRequirements(SonarMojo.java:159)
	at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:132)
	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)
	... 20 more
[ERROR] 
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
SonarQube analysis completed: FAILURE
Build step 'SonarQube analysis with Maven' changed build result to FAILURE
Build step 'SonarQube analysis with Maven' marked build as failure
Sending e-mails to: xxxxxxxxxxxxxxxxx
No emails were triggered.
Warning: you have no plugins providing access control for builds, so falling back to legacy behavior of permitting any downstream builds to be triggered
Finished: FAILURE


Jenkins 1.642.4
Sonar 7.0
Maven 3.3
sonar-maven-plugin 2.5
Java 1.8.151

Full disclosure: I am NOT a java developer or really knowledgeable about these compatibility issues. I can usually make my way be paying attention to the log messages and either correcting the obvious errors or googling a solution or clue to one.
So I am really flummoxed on how to get this to work. I don't want to tell my devs to go back to maven 2.x and I don't want to rollback to sonarqube 5.6.6
Thanks in advance for your help.  

Tibor Blenessy

unread,
Mar 6, 2018, 2:42:29 AM3/6/18
to ghst...@gmail.com, SonarQube
Hello,

you are using really old version of sonar-maven-plugin, current version is 3.4. See documentation here  about different ways how to specify the version.

Hope that helps

Tibor

--
You received this message because you are subscribed to the Google Groups "SonarQube" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sonarqube+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sonarqube/8cce6ded-bbc9-44bf-8bc9-4513c5174ec7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--

Tibor Blenessy | SonarSource

Language Analyzer Developer

https://sonarsource.com 

Message has been deleted

Mike Gracy

unread,
Mar 6, 2018, 4:04:03 PM3/6/18
to SonarQube
Thank for your response, but I've been to that page numerous times and haven't found a place to download the plugin jar.
Another thought just occurred, is this something i just update in the pom?

Tibor Blenessy

unread,
Mar 7, 2018, 4:17:49 AM3/7/18
to Mike Gracy, SonarQube
Hello,

yes, you either set it in your pom, or in the script which launches the analysis (as described on that page). You don't need to download the plugin jar, this is managed by maven.

Tibor


For more options, visit https://groups.google.com/d/optout.

Mike Gracy

unread,
Mar 7, 2018, 7:26:46 PM3/7/18
to SonarQube
Thank you!


On Wednesday, March 7, 2018 at 1:17:49 AM UTC-8, Tibor Blenessy wrote:
Hello,

Reply all
Reply to author
Forward
0 new messages