You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Andreas Guther <An...@markettools.com> on 2006/03/19 04:33:49 UTC

[M2] Maven Generated Reports

Hi,

I am searching for an overview of the available Maven 2 report plug-ins
besides the standard ones.

I found an example for pmd but I wonder if there is a somewhere a
collection of available reports like JUnit, JDepend, etc. with examples
for configuring them.

Of course I could look into the code of each plug-in...

Just wondering if there is an info page.

Thanks in advance for any hint.

Andreas




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


Re: [M2] Maven Generated Reports

Posted by Rune Flobakk <rf...@online.no>.
Worked like a charm here too! Thanks! And the reports are more 
nice-looking than the jcoverage reports I got in my Maven 1 projects.

Yep, you are correct Boris, I'm from Norway. Was just kidding around 
about the German/Swedish/European decimal number thingie, Hope no one 
took it seriously :)

I hope Andreas Guther who was the initial poster in this thread got some 
useful tips on how Maven 2 handles reporting as well, as I pretty much 
hi-jacked the thread ;-) I know I learned a lot from you guys at least.

Rune

Subhash Chandran skrev:
> Thanks for the cobertura tip! It works like a magic!! I had spent so much
> time trying to make it work for me!
> 
> Regards,
> Subhash.
> 
> On 3/19/06, Boris Lenzinger <bo...@gmail.com> wrote:
>> I Use cobertura plugin with Maven 2 and it works fine.
>>
>>       <plugin>
>>         <groupId>org.codehaus.mojo</groupId>
>>         <artifactId>cobertura-maven-plugin</artifactId>
>>         <version>2.0-20060130.214008-3</version>
>>       </plugin>
>>
>> (I had to add this in the pluginRepositories section):
>>     <pluginRepository>
>>       <id>CodeHaus</id>
>>       <name></name>
>>       <url>http://snapshots.maven.codehaus.org/maven2</url>
>>       <layout>default</layout>
>>       <snapshots>
>>         <enabled>true</enabled>
>>       </snapshots>
>>       <releases>
>>         <enabled>false</enabled>
>>         <updatePolicy>never</updatePolicy>
>>       </releases>
>>     </pluginRepository>
>>
>> Reports generated are great really.
>>
>> About the numbers, I guess Rune is from Norway with ".no" suffix ?
>>
>> Boris
>>
>>
> 

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


Re: [M2] Maven Generated Reports

Posted by Subhash Chandran <su...@gmail.com>.
Thanks for the cobertura tip! It works like a magic!! I had spent so much
time trying to make it work for me!

Regards,
Subhash.

On 3/19/06, Boris Lenzinger <bo...@gmail.com> wrote:
>
> I Use cobertura plugin with Maven 2 and it works fine.
>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>cobertura-maven-plugin</artifactId>
>         <version>2.0-20060130.214008-3</version>
>       </plugin>
>
> (I had to add this in the pluginRepositories section):
>     <pluginRepository>
>       <id>CodeHaus</id>
>       <name></name>
>       <url>http://snapshots.maven.codehaus.org/maven2</url>
>       <layout>default</layout>
>       <snapshots>
>         <enabled>true</enabled>
>       </snapshots>
>       <releases>
>         <enabled>false</enabled>
>         <updatePolicy>never</updatePolicy>
>       </releases>
>     </pluginRepository>
>
> Reports generated are great really.
>
> About the numbers, I guess Rune is from Norway with ".no" suffix ?
>
> Boris
>
>

Re: [M2] Maven Generated Reports

Posted by Boris Lenzinger <bo...@gmail.com>.
I Use cobertura plugin with Maven 2 and it works fine.

      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>cobertura-maven-plugin</artifactId>
        <version>2.0-20060130.214008-3</version>
      </plugin>

(I had to add this in the pluginRepositories section):
    <pluginRepository>
      <id>CodeHaus</id>
      <name></name>
      <url>http://snapshots.maven.codehaus.org/maven2</url>
      <layout>default</layout>
      <snapshots>
        <enabled>true</enabled>
      </snapshots>
      <releases>
        <enabled>false</enabled>
        <updatePolicy>never</updatePolicy>
      </releases>
    </pluginRepository>

Reports generated are great really.

About the numbers, I guess Rune is from Norway with ".no" suffix ?

Boris

Wayne Fay a écrit :
> I just know the other guys who had the same problem were German. I
> suppose I should have said "European-style numbers" ? Or what is it
> called when you use period for thousands and comma for decimal place?
>
> As for Cobertura, just give it a couple weeks for Maven 2.0.3 to be
> out and official and then Cobertura should follow shortly thereafter,
> without needing to check anything out of SVN etc... You should be able
> to simply add it in <reporting>.
>
> Wayne
>
>
> On 3/18/06, Rune Flobakk <rf...@online.no> wrote:
>   
>> Wayne Fay wrote:
>>     
>>> No that's because the plugin doesn't understand your German-style numbers. ;-)
>>>       
>> German-style, eh? Oh well, at least you didn't call it Swedish-style,
>> now that would have been a serious insult ;-)
>>
>>
>>     
>>> This was discussed in an email thread a few weeks ago...
>>>
>>> Subject
>>> [m202] NumberFormatException when using the surefire report plugin
>>> ######
>>> This error is indeed caused by the german locale. Simply change the
>>> locale that Maven uses (on Windows):
>>>
>>> set MAVEN_OPTS=-Duser.language=en -Duser.country=US
>>> ######
>>>       
>> Thanks for the info!
>>
>> Rune
>>
>>
>>     
>>> Wayne
>>>
>>>       
>> ---------------------------------------------------------------------
>> 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


Re: [M2] Maven Generated Reports

Posted by Wayne Fay <wa...@gmail.com>.
I just know the other guys who had the same problem were German. I
suppose I should have said "European-style numbers" ? Or what is it
called when you use period for thousands and comma for decimal place?

As for Cobertura, just give it a couple weeks for Maven 2.0.3 to be
out and official and then Cobertura should follow shortly thereafter,
without needing to check anything out of SVN etc... You should be able
to simply add it in <reporting>.

Wayne


On 3/18/06, Rune Flobakk <rf...@online.no> wrote:
> Wayne Fay wrote:
> > No that's because the plugin doesn't understand your German-style numbers. ;-)
>
> German-style, eh? Oh well, at least you didn't call it Swedish-style,
> now that would have been a serious insult ;-)
>
>
> > This was discussed in an email thread a few weeks ago...
> >
> > Subject
> > [m202] NumberFormatException when using the surefire report plugin
> > ######
> > This error is indeed caused by the german locale. Simply change the
> > locale that Maven uses (on Windows):
> >
> > set MAVEN_OPTS=-Duser.language=en -Duser.country=US
> > ######
>
> Thanks for the info!
>
> Rune
>
>
> >
> > Wayne
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: [M2] Maven Generated Reports

Posted by Rune Flobakk <rf...@online.no>.
Wayne Fay wrote:
> No that's because the plugin doesn't understand your German-style numbers. ;-)

German-style, eh? Oh well, at least you didn't call it Swedish-style, 
now that would have been a serious insult ;-)


> This was discussed in an email thread a few weeks ago...
> 
> Subject
> [m202] NumberFormatException when using the surefire report plugin
> ######
> This error is indeed caused by the german locale. Simply change the
> locale that Maven uses (on Windows):
> 
> set MAVEN_OPTS=-Duser.language=en -Duser.country=US
> ######

Thanks for the info!

Rune


> 
> Wayne
> 

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


Re: [M2] Maven Generated Reports

Posted by Wayne Fay <wa...@gmail.com>.
No that's because the plugin doesn't understand your German-style numbers. ;-)

This was discussed in an email thread a few weeks ago...

Subject
[m202] NumberFormatException when using the surefire report plugin
######
This error is indeed caused by the german locale. Simply change the
locale that Maven uses (on Windows):

set MAVEN_OPTS=-Duser.language=en -Duser.country=US
######

Wayne

On 3/18/06, Rune Flobakk <rf...@online.no> wrote:
> Thanks for the heads-up regarding the
>  >       <plugin>
>  >         <groupId>org.codehaus.mojo</groupId>
>  >         <artifactId>surefire-report-maven-plugin</artifactId>
>  >       </plugin>
>
> Resulted in a somewhat buggy testing report at least. Got an ugly
> stacktrace from the surefire-report-maven-plugin while running 'mvn
> site' caused by a NumberFormatException: For input string: "0,047".
>
> I did install the newest snapshot-version of the site plugin. Maybe I
> should revert to the old one...
>
> Rune
>
>
> Wayne Fay wrote:
> > No such page exists, that I have ever seen...
> >
> > Here's the reporting section from one of my poms, though:
> >
> >   <reporting>
> >     <plugins>
> >       <plugin>
> >         <groupId>org.apache.maven.plugins</groupId>
> >         <artifactId>maven-project-info-reports-plugin</artifactId>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.apache.maven.plugins</groupId>
> >         <artifactId>maven-javadoc-plugin</artifactId>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.codehaus.mojo</groupId>
> >         <artifactId>jxr-maven-plugin</artifactId>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.codehaus.mojo</groupId>
> >         <artifactId>jdepend-maven-plugin</artifactId>
> >         <version>2.0-beta-1-SNAPSHOT</version>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.codehaus.mojo</groupId>
> >         <artifactId>findbugs-maven-plugin</artifactId>
> >         <version>1.0-SNAPSHOT</version>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.codehaus.mojo</groupId>
> >         <artifactId>surefire-report-maven-plugin</artifactId>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.codehaus.mojo</groupId>
> >         <artifactId>javancss-maven-plugin</artifactId>
> >         <version>2.0-alpha1-SNAPSHOT</version>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.codehaus.mojo</groupId>
> >         <artifactId>taglist-maven-plugin</artifactId>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.apache.maven.plugins</groupId>
> >         <artifactId>maven-checkstyle-plugin</artifactId>
> >       </plugin>
> >       <plugin>
> >         <groupId>org.apache.maven.plugins</groupId>
> >         <artifactId>maven-pmd-plugin</artifactId>
> >       </plugin>
> >     </plugins>
> >   </reporting>
> >
> > There is a <configuration> elements for many of the plugins, and I'm
> > using a few of them... but in general, reports work fine with no
> > configuration settings, so you can just use the default.
> >
> > Any one else using other plugins? Obviously Cobertura is available if
> > you are using Maven 2.0.3, but any others?
> >
> > HTH.
> > Wayne
> >
> >
> > On 3/18/06, Andreas Guther <An...@markettools.com> wrote:
> >> Hi,
> >>
> >> I am searching for an overview of the available Maven 2 report plug-ins
> >> besides the standard ones.
> >>
> >> I found an example for pmd but I wonder if there is a somewhere a
> >> collection of available reports like JUnit, JDepend, etc. with examples
> >> for configuring them.
> >>
> >> Of course I could look into the code of each plug-in...
> >>
> >> Just wondering if there is an info page.
> >>
> >> Thanks in advance for any hint.
> >>
> >> Andreas
> >>
> >>
> >>
> >>
> >> ---------------------------------------------------------------------
> >> 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
>
>

Re: [M2] Maven Generated Reports

Posted by Rune Flobakk <rf...@online.no>.
Thanks for the heads-up regarding the
 >       <plugin>
 >         <groupId>org.codehaus.mojo</groupId>
 >         <artifactId>surefire-report-maven-plugin</artifactId>
 >       </plugin>

Resulted in a somewhat buggy testing report at least. Got an ugly 
stacktrace from the surefire-report-maven-plugin while running 'mvn 
site' caused by a NumberFormatException: For input string: "0,047".

I did install the newest snapshot-version of the site plugin. Maybe I 
should revert to the old one...

Rune


Wayne Fay wrote:
> No such page exists, that I have ever seen...
> 
> Here's the reporting section from one of my poms, though:
> 
>   <reporting>
>     <plugins>
>       <plugin>
>         <groupId>org.apache.maven.plugins</groupId>
>         <artifactId>maven-project-info-reports-plugin</artifactId>
>       </plugin>
>       <plugin>
>         <groupId>org.apache.maven.plugins</groupId>
>         <artifactId>maven-javadoc-plugin</artifactId>
>       </plugin>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>jxr-maven-plugin</artifactId>
>       </plugin>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>jdepend-maven-plugin</artifactId>
>         <version>2.0-beta-1-SNAPSHOT</version>
>       </plugin>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>findbugs-maven-plugin</artifactId>
>         <version>1.0-SNAPSHOT</version>
>       </plugin>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>surefire-report-maven-plugin</artifactId>
>       </plugin>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>javancss-maven-plugin</artifactId>
>         <version>2.0-alpha1-SNAPSHOT</version>
>       </plugin>
>       <plugin>
>         <groupId>org.codehaus.mojo</groupId>
>         <artifactId>taglist-maven-plugin</artifactId>
>       </plugin>
>       <plugin>
>         <groupId>org.apache.maven.plugins</groupId>
>         <artifactId>maven-checkstyle-plugin</artifactId>
>       </plugin>
>       <plugin>
>         <groupId>org.apache.maven.plugins</groupId>
>         <artifactId>maven-pmd-plugin</artifactId>
>       </plugin>
>     </plugins>
>   </reporting>
> 
> There is a <configuration> elements for many of the plugins, and I'm
> using a few of them... but in general, reports work fine with no
> configuration settings, so you can just use the default.
> 
> Any one else using other plugins? Obviously Cobertura is available if
> you are using Maven 2.0.3, but any others?
> 
> HTH.
> Wayne
> 
> 
> On 3/18/06, Andreas Guther <An...@markettools.com> wrote:
>> Hi,
>>
>> I am searching for an overview of the available Maven 2 report plug-ins
>> besides the standard ones.
>>
>> I found an example for pmd but I wonder if there is a somewhere a
>> collection of available reports like JUnit, JDepend, etc. with examples
>> for configuring them.
>>
>> Of course I could look into the code of each plug-in...
>>
>> Just wondering if there is an info page.
>>
>> Thanks in advance for any hint.
>>
>> Andreas
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> 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


Re: [M2] Maven Generated Reports

Posted by Wayne Fay <wa...@gmail.com>.
No such page exists, that I have ever seen...

Here's the reporting section from one of my poms, though:

  <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-project-info-reports-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>jxr-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>jdepend-maven-plugin</artifactId>
        <version>2.0-beta-1-SNAPSHOT</version>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>findbugs-maven-plugin</artifactId>
        <version>1.0-SNAPSHOT</version>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>surefire-report-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>javancss-maven-plugin</artifactId>
        <version>2.0-alpha1-SNAPSHOT</version>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>taglist-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-pmd-plugin</artifactId>
      </plugin>
    </plugins>
  </reporting>

There is a <configuration> elements for many of the plugins, and I'm
using a few of them... but in general, reports work fine with no
configuration settings, so you can just use the default.

Any one else using other plugins? Obviously Cobertura is available if
you are using Maven 2.0.3, but any others?

HTH.
Wayne


On 3/18/06, Andreas Guther <An...@markettools.com> wrote:
> Hi,
>
> I am searching for an overview of the available Maven 2 report plug-ins
> besides the standard ones.
>
> I found an example for pmd but I wonder if there is a somewhere a
> collection of available reports like JUnit, JDepend, etc. with examples
> for configuring them.
>
> Of course I could look into the code of each plug-in...
>
> Just wondering if there is an info page.
>
> Thanks in advance for any hint.
>
> Andreas
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: [M2] Maven Generated Reports

Posted by Rune Flobakk <rf...@online.no>.
Wayne Fay wrote:
>> http://www.javaworld.com/javaworld/jw-02-2006/jw-0227-maven.html
> That's a good article, I've referred to it myself a bit.
> 
>> maven-surefire-plugin doesn't even seem to start, and the
>> maven-clover-plugin complains about an expired licence...
> 
> Clover is not "free". Its a product from www.cenqua.com. They provide
> free licenses to Open source projects like Maven but in general you
> have to pay for it. Which is part of the reason why Cobertura is being
> created. ;-)

I just made an attempt to check out Cobertura, but the svn-url was 
wrong, the http browsing url of the svn repository was wrong... In 
short, I think I'll call it a night now. I'll probably be alot more 
ready to fiddle around with Maven 2 some time later, but right now I'm 
mostly tempted to revert to good old 'javac *.java' exclusively ;-D

Cheers. Later!

Rune



> 
> 
> Wayne


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


Re: [M2] Maven Generated Reports

Posted by Wayne Fay <wa...@gmail.com>.
> http://www.javaworld.com/javaworld/jw-02-2006/jw-0227-maven.html
That's a good article, I've referred to it myself a bit.

> maven-surefire-plugin doesn't even seem to start, and the
> maven-clover-plugin complains about an expired licence...

Clover is not "free". Its a product from www.cenqua.com. They provide
free licenses to Open source projects like Maven but in general you
have to pay for it. Which is part of the reason why Cobertura is being
created. ;-)


Wayne

Re: [M2] Maven Generated Reports

Posted by Rune Flobakk <rf...@online.no>.
I am struggling with the same thing right now, and found this guide as a 
good starting point: 
http://www.javaworld.com/javaworld/jw-02-2006/jw-0227-maven.html

Only thing is, I've tried to include javadoc-report, junit-report 
(surefire), and coverage-report (clover) to my reporting section in the 
POM, but it's only the javadoc which is generated. The 
maven-surefire-plugin doesn't even seem to start, and the 
maven-clover-plugin complains about an expired licence...

I have defined this in my reporting section:
<reporting>
   <plugins>

     <plugin>
       <groupId>org.apache.maven.plugins</groupId>
       <artifactId>maven-project-info-reports-plugin</artifactId>
       <reportSets>
         <reportSet>
           <reports>
             <report>project-team</report>
           </reports>
         </reportSet>
       </reportSets>
     </plugin>

     <plugin>
       <groupId>org.apache.maven.plugins</groupId>
       <artifactId>maven-javadoc-plugin</artifactId>
     </plugin>

     <plugin>
       <groupId>org.apache.maven.plugins</groupId>
       <artifactId>maven-surefire-plugin</artifactId>
     </plugin>

     <!--plugin>
       <groupId>org.apache.maven.plugins</groupId>
       <artifactId>maven-clover-plugin</artifactId>
     </plugin-->

   </plugins>
</reporting>

When running 'mvn test' the testing completes fine, but still it's not 
included when running 'mvn site'

Rune




Andreas Guther wrote:
> Hi,
> 
> I am searching for an overview of the available Maven 2 report plug-ins
> besides the standard ones.
> 
> I found an example for pmd but I wonder if there is a somewhere a
> collection of available reports like JUnit, JDepend, etc. with examples
> for configuring them.
> 
> Of course I could look into the code of each plug-in...
> 
> Just wondering if there is an info page.
> 
> Thanks in advance for any hint.
> 
> Andreas
> 
> 
> 
> 
> ---------------------------------------------------------------------
> 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