wood burning stoves 2.0*
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
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven-checkstyle-plugin error" Watch "Maven-checkstyle-plugin error" New topic
Author

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 java.lang.Thread.run(Thread.java:662)

Caused by: java.lang.NoSuchMethodError: hudson.plugins.checkstyle.CheckStyleReporter.getModuleName(Lorg/apache/maven/project/MavenProject;)Ljava/lang/String;
at hudson.plugins.checkstyle.CheckStyleReporter.perform(CheckStyleReporter.java:81)
at hudson.plugins.analysis.core.HealthAwareMavenReporter.postExecute(HealthAwareMavenReporter.java:197)
at hudson.maven.Maven3Builder$MavenExecutionListener.reccordMojoSucceeded(Maven3Builder.java:568)
at hudson.maven.Maven3Builder$MavenExecutionListener.mojoSucceeded(Maven3Builder.java:531)
at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire(DefaultExecutionEventCatapult.java:87)
at org.apache.maven.lifecycle.internal.DefaultExecutionEventCatapult.fire(DefaultExecutionEventCatapult.java:42)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:228)
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:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.jvnet.hudson.maven3.launcher.Maven3Launcher.main(Maven3Launcher.java:79)
Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5812
    
    7

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: http://aspose.com/file-tools
 
subject: Maven-checkstyle-plugin error
 
Similar Threads
java.lang.IllegalArgumentException: Document base D:\Workspace\Db\strutsandhibernte\src\main\webapp
Tomcat - Struts app Startup Error
Cannot find setter nor field in org.apache.maven.plugins.site.ReportPlugin
Maven: No SCM URL was provided to perform the release from
"Reason: Auth cancel" while uploading war onto remote server via jenkins and maven