Issue Details (XML | Word | Printable)

Key: MOJO-1012
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: David Vicente
Reporter: Christoph Ewerlin
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Mojo

Broken links in multimodule reports because of artifactId != directory name

Created: 25/Jan/08 06:51 AM   Updated: 10/Feb/08 12:44 PM  Due: 10/Feb/08
Component/s: dashboard
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

File Attachments: 1. Zip Archive dashboard_broken_link.zip (2 kB)
2. Text File MOJO-1012.patch (2 kB)


Complexity: Intermediate


 Description  « Hide
Links in dashboard detailed reports are broken, if the directory a submodule was in during build does not match the artifact id.

Consider the following setup:

pom.xml

– module1
— pom.xml
— some java sources

where main pom includes module1:
<modules>
<module>module1</module>
</modules>

but artifact id of the project in directory module1 is e.g. "dashboard_broken_link.module1"
<groupId>com.sdm.foo</groupId>
<artifactId>dashboard_broken_link.module1</artifactId>

Building a maven site and deploying it with mvn site:deploy will result in the following directory structure on the server:

– dashboard-report.html
– dashboard-report-details.html
– dashboard_broken_link.module1 (directory)
– dashboard-report.html

The link in when clicking on e.g. "Checkstyle Report Summary" and "Dashboard Broken Link Example Module1" will point to "/module1/dashboard-report.html#checkstyle" instead of "/dashboard_broken_link.module1/dashboard-report.html#checkstyle".

Seems to be a bug for me, or is it just something I am missing here?
Find a toy project included in the attachment.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
David Vicente added a comment - 25/Jan/08 07:22 AM
HI,

could you give me the maven's version you used to make your build ?

I've had this problem before with directory's name and artifactId which are different but i've already corrected

Best regards

David


Christoph Ewerlin added a comment - 25/Jan/08 07:30 AM
Hi David,
I'm using maven 2.0.7.

I have done some further investigation and this is probably not because of the directory structure, but because the artifactId contains a dot character.
I renamed the artifact to "dashboard_broken_link.module4711" and a link to "/module4711" is created.
Probably the plugin strips everything before the last dot of groupId:artifactId?
The dashboard-report.xml in module1 only has a line
<dashboard artefactId="com.sdm.foo.dashboard_broken_link.module4711">
and does not differentiate groupId and artifactId?

Best regards
Christoph


Christoph Ewerlin added a comment - 30/Jan/08 09:50 AM
I wrote a patch for this issue, which solves the problem in my case.
The DashBoardMultiReport stripped everything before the last dot - character from the artitfactId to generate a link.
I'm not sure, if this was in some way an intended behaviour?

David Vicente added a comment - 09/Feb/08 02:01 PM
ok done

David Vicente added a comment - 10/Feb/08 12:44 PM
released this day, February 10th 2008 as 1. 0-SNAPSHOT : dashboard-maven-plugin-1.0-20080210.183905-16.jar