You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Lewis, Eric" <Er...@ipi.ch> on 2008/11/03 13:26:11 UTC

AW: Checkstyle plugin: configLocation ignored?

Anyone?  :-) 

> 
> Hi
> 
> I'm trying to use the Checkstyle plugin with one central 
> checkstyle.xml
> configuration for all projects.
> I set up a web server which has the file at
> http://buildconfig.ipie.ch/checkstyle/checkstyle.xml
> 
> I configured this in my POM:
>         <plugin>
>           <groupId>org.apache.maven.plugins</groupId>
>           <artifactId>maven-checkstyle-plugin</artifactId>
>           <configuration>
>  
> <configLocation>http://buildconfig.ipie.ch/checkstyle/checksty
le.xml</co
> nfigLocation>
>             <enableRSS>false</enableRSS>
>  
> <includeTestSourceDirectory>true</includeTestSourceDirectory>
>           </configuration>
>         </plugin>
> 
> Then I used 'mvn -e -X checkstyle:checkstyle' on my project, but it
> seems that the configLocation is read, but then ignored (?)
> 
> [DEBUG] Configuring mojo
> 'org.apache.maven.plugins:maven-checkstyle-plugin:2.2:checkstyle' -->
> [DEBUG]   (f) cacheFile =
> /ige/temp/continuous_integration/ipi-utils/time-util/target/ch
eckstyle-c
> achefile
> [DEBUG]   (f) configLocation =
> http://buildconfig.ipie.ch/checkstyle/checkstyle.xml
> [DEBUG]   (f) consoleOutput = false
> [DEBUG]   (f) enableFilesSummary = true
> [DEBUG]   (f) enableRSS = false
> [DEBUG]   (f) enableRulesSummary = true
> [DEBUG]   (f) enableSeveritySummary = true
> [DEBUG]   (f) encoding = UTF-8
> [DEBUG]   (f) failsOnError = false
> [DEBUG]   (f) format = sun
> [DEBUG]   (f) headerFile =
> /ige/temp/continuous_integration/ipi-utils/time-util/LICENSE.txt
> [DEBUG]   (f) headerLocation = LICENSE.txt
> [DEBUG]   (f) includeTestSourceDirectory = true
> [DEBUG]   (f) includes = **/*.java
> [DEBUG]   (f) linkXRef = true
> [DEBUG]   (f) outputDirectory =
> /ige/temp/continuous_integration/ipi-utils/time-util/target/site
> [DEBUG]   (f) outputFile =
> /ige/temp/continuous_integration/ipi-utils/time-util/target/ch
eckstyle-r
> esult.xml
> [DEBUG]   (f) outputFileFormat = xml
> [DEBUG]   (f) project = MavenProject: 
> ch.ipi:time-util:1.0.0-SNAPSHOT @
> /ige/temp/continuous_integration/ipi-utils/time-util/pom.xml
> [DEBUG]   (f) skip = false
> [DEBUG]   (f) sourceDirectory =
> /ige/temp/continuous_integration/ipi-utils/time-util/src/main/java
> [DEBUG]   (f) suppressionsFileExpression = 
> checkstyle.suppressions.file
> [DEBUG]   (f) testSourceDirectory =
> /ige/temp/continuous_integration/ipi-utils/time-util/src/test/java
> [DEBUG]   (f) xrefLocation =
> /ige/temp/continuous_integration/ipi-utils/time-util/target/site/xref
> [DEBUG] -- end configuration --
> [INFO] [checkstyle:checkstyle]
> [DEBUG] URLResourceLoader: Found
> 'http://buildconfig.ipie.ch/checkstyle/checkstyle.xml' at ''
> [DEBUG] The resource
> 'http://buildconfig.ipie.ch/checkstyle/checkstyle.xml' found using the
> org.codehaus.plexus.resource.loader.URLResourceLoader@79a61172.
> [DEBUG] The resource 'LICENSE.txt' found using the
> org.codehaus.plexus.resource.loader.ThreadContextClasspathReso
> urceLoader
> @58648016.
> [INFO]
> --------------------------------------------------------------
> ----------
> [ERROR] BUILD ERROR
> [INFO]
> --------------------------------------------------------------
> ----------
> [INFO] An error has occurred in Checkstyle report generation.
> 
> Embedded error: Failed during checkstyle configuration
> Connection timed out
> [INFO]
> --------------------------------------------------------------
> ----------
> [DEBUG] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: An error has
> occurred in Checkstyle report generation.
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoa
> ls(Default
> LifecycleExecutor.java:583)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeSta
> ndaloneGoa
> l(DefaultLifecycleExecutor.java:512)
> ...
> Caused by: org.apache.maven.plugin.MojoExecutionException: An 
> error has
> occurred in Checkstyle report generation.
>         at
> org.apache.maven.reporting.AbstractMavenReport.execute(Abstrac
> tMavenRepo
> rt.java:79)
>         at
> org.apache.maven.plugin.DefaultPluginManager.executeMojo(Defau
> ltPluginMa
> nager.java:451)
>         at
> org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoa
> ls(Default
> LifecycleExecutor.java:558)
>         ... 16 more
> Caused by: org.apache.maven.reporting.MavenReportException: Failed
> during checkstyle configuration
>         at
> org.apache.maven.plugin.checkstyle.CheckstyleReport.executeRep
> ort(Checks
> tyleReport.java:648)
>         at
> org.apache.maven.reporting.AbstractMavenReport.generate(Abstra
> ctMavenRep
> ort.java:98)
>         at
> org.apache.maven.reporting.AbstractMavenReport.execute(Abstrac
> tMavenRepo
> rt.java:73)
>         ... 18 more
> Caused by: com.puppycrawl.tools.checkstyle.api.CheckstyleException:
> unable to read
> /ige/temp/continuous_integration/ipi-utils/time-util/target/ch
eckstyle-c
> hecker.xml - unable to read from stream
>         at
> com.puppycrawl.tools.checkstyle.ConfigurationLoader.loadConfig
> uration(Co
> nfigurationLoader.java:309)
>         at
> com.puppycrawl.tools.checkstyle.ConfigurationLoader.loadConfig
> uration(Co
> nfigurationLoader.java:268)
>         at
> org.apache.maven.plugin.checkstyle.CheckstyleReport.executeRep
> ort(Checks
> tyleReport.java:607)
>         ... 20 more
> Caused by: com.puppycrawl.tools.checkstyle.api.CheckstyleException:
> unable to read from stream
>         at
> com.puppycrawl.tools.checkstyle.ConfigurationLoader.loadConfig
> uration(Co
> nfigurationLoader.java:361)
>         at
> com.puppycrawl.tools.checkstyle.ConfigurationLoader.loadConfig
> uration(Co
> nfigurationLoader.java:298)
>         ... 22 more
> Caused by: java.net.ConnectException: Connection timed out
>         at java.net.PlainSocketImpl.socketConnect(Native Method)
>         at 
> java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
>         at
> java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
> ...
> 
> 
> From what I understand, the configuration file is read and then copied
> into the project, but I have no clue why Maven can't read it 
> from there,
> because it exists and I can read it (with the same user). Any ideas?
> 
> Btw, I since read that checkstyle:check should be used (since I'm not
> using the 'site' goal). I tried that too, but it doesn't work either.
> 
> Best regards,
> Eric
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org