This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven-checkstyle-plugin error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven-checkstyle-plugin error" Watch "Maven-checkstyle-plugin error" New topic

Maven-checkstyle-plugin error

Abhijith Prabhakar
Ranch Hand

Joined: Dec 29, 2006
Posts: 56
I am setting up hudson for checkstyle. I have installed checkstyle 3.9 and Static code analysis plug-in 1.9 version. I am using maven-checkstyle-plugin version 2.6 locally and this is working fine.

But in Hudson I am gettting below error. Any leads on how to solve this?at

Caused by: java.lang.NoSuchMethodError: hudson.plugins.checkstyle.CheckStyleReporter.getModuleName(Lorg/apache/maven/project/MavenProject;)Ljava/lang/String;
at hudson.plugins.checkstyle.CheckStyleReporter.perform(
at hudson.plugins.analysis.core.HealthAwareMavenReporter.postExecute(
at hudson.maven.Maven3Builder$MavenExecutionListener.reccordMojoSucceeded(
at hudson.maven.Maven3Builder$MavenExecutionListener.mojoSucceeded(
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(
at org.apache.maven.DefaultMaven.doExecute(
at org.apache.maven.DefaultMaven.execute(
at org.jvnet.hudson.maven3.launcher.Maven3Launcher.main(
Peter Johnson

Joined: May 14, 2008
Posts: 5811

My guess is that there is a version mismatch between the checkstyle plugin and Hudson. The solution would be to install the proper version of the checkstyle plugin.

Another possibility is that the plugin got corrupted during the download. (I'm sort of leaning towards this because how else could the perform() method in the CheckStyleReporter be calling a non-existent method in that same class?)

JBoss In Action
Abhijith Prabhakar
Ranch Hand

Joined: Dec 29, 2006
Posts: 56
Thanks peter,

There was a mismatch between checkstyle and analysis core plugin. Got fixed once I put correct analysis core plugin to hudson.

Thanks for your help.

I agree. Here's the link:
subject: Maven-checkstyle-plugin error
Similar Threads
Cannot find setter nor field in
Maven: No SCM URL was provided to perform the release from
Tomcat - Struts app Startup Error
"Reason: Auth cancel" while uploading war onto remote server via jenkins and maven
java.lang.IllegalArgumentException: Document base D:\Workspace\Db\strutsandhibernte\src\main\webapp