You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Stefan Hansel (JIRA)" <ji...@codehaus.org> on 2011/01/31 18:13:57 UTC

[jira] Created: (MSITE-548) site:deploy -> folder structure is different when artifactId=module's directory

site:deploy -> folder structure is different when artifactId=module's directory
-------------------------------------------------------------------------------

                 Key: MSITE-548
                 URL: http://jira.codehaus.org/browse/MSITE-548
             Project: Maven 2.x and 3.x Site Plugin
          Issue Type: Bug
    Affects Versions: 3.0-beta-3
         Environment: windows
            Reporter: Stefan Hansel
         Attachments: artifact-id-testcase.zip

There is a multimodule flat project structure:
root
module1
module2

module1 has an artifactID of 'module1'  (same as directory name)
modulu2 has an artifactID of 'module-2' (different to directory name)

After a 'mvn site-deploy' the generated report has the folder structure:
/root
/root/module-2
/module1

So based on the artifactID the submodules are created as a child of the root - or not.
This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.

This is also important for other plugins (i.e. the dashboard plugin).
They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 

Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=259315#action_259315 ] 

Benjamin Bentmann commented on MNG-5000:
----------------------------------------

I already mentioned {{getModulePathAdjustment()}}.

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>             Fix For: 3.0.3
>
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=256949#action_256949 ] 

Benjamin Bentmann commented on MNG-5000:
----------------------------------------

You're right about this being a core issue, I missed to recognize the discrepancy in the module-2 project, fixed in [r1072613|http://svn.apache.org/viewvc?view=revision&revision=1072613].

The cause of the issue was that module-2 has a different artifactId than its module name. Let me stress that such a layout is a recipe for trouble as it results in effective URLs that depend on the source of the POM (project vs repo), i.e. if somebody (e.g. a plugin) was to construct the POM of this project from the repository, it would see different URLs than those used when building the project. The same problem would also arise during local project building when URLs are inherited from a grand-parent via one or more intermediate parents and any of those parents is resolved from the repo. For this reason, it's highly recommended to synchronize the module name with the artifactId.

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>             Fix For: 3.0.3
>
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=257415#action_257415 ] 

Benjamin Bentmann commented on MNG-5000:
----------------------------------------

bq. I don't understand why this should be the case, are there any docs or examples you could point me to?

http://svn.apache.org/repos/asf/maven/maven-2/tags/maven-2.2.1/maven-project/src/main/java/org/apache/maven/project/MavenProject.java, getModulePathAdjustment() starts with two nice FIXME comments that outline the design flaw.

bq. The state of a pom should be uniquely specified by its maven coordinates and those of its parent, not by the module structure of the build

Yes this would be the ideal but the bug raised here demands to consider the directory name in the local project structure which is lost once the POMs got installed/deployed to a repo. When I investigated the bug, I was originally tempted to close it as won't fix because of the irreproducibility it drags in but then again, this entire URL inheritance/adjustment feature is broken itself so I stopped bothering and just restored the status quo as in 2.x.

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>             Fix For: 3.0.3
>
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=257384#action_257384 ] 

Lukas Theussl commented on MNG-5000:
------------------------------------

bq. such a layout is a recipe for trouble as it results in effective URLs that depend on the source of the POM (project vs repo)

If this is true then there must be something wrong with Maven... ;)

bq. it would see different URLs than those used when building the project

I don't understand why this should be the case, are there any docs or examples you could point me to? The state of a pom should be uniquely specified by its maven coordinates and those of its parent, not by the module structure of the build. In other words, why shouldn't it be possible to move a module into a different directory, without changing the module's identity?

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>             Fix For: 3.0.3
>
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Reopened: (MNG-5000) child distributionManagment.site.url not correct in a flat directory layout

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Stefan Hansel reopened MNG-5000:
--------------------------------


see last comment

> child distributionManagment.site.url not correct in a flat directory layout
> ---------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) child distributionManagment.site.url not correct in a flat directory layout

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=255941#action_255941 ] 

Lukas Theussl commented on MNG-5000:
------------------------------------

I agree with Stefan that there is an issue somewhere and since it can be demonstrated by just help:effective-pom, it's not site-plugin specific. However, I am confused about what the actual expected behavior is, MNG-3134 sounds just wrong to me as it supposes the module structure matches the inheritance structure IIUC. I will try to construct a clearer test case for demonstration.

> child distributionManagment.site.url not correct in a flat directory layout
> ---------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=259314#action_259314 ] 

Lukas Theussl commented on MNG-5000:
------------------------------------

I'm still confused about this... Benjamin: what's the actual algorithm to calculate the effective url if it gets inherited? The current [site docs|http://maven.apache.org/plugins/maven-site-plugin/usage.html] say:

{noformat}
If subprojects inherit the site URL from a parent POM, they will automatically append their <artifactId> to form their effective deployment location.
{noformat}

This is what I always had in mind but it is obviously not correct for the attached test project (the modules get deployed into the same directory as root, instead of having their artifactId appended). At least the behavior is consistent now AFAIS so I guess the docs need to be adjusted. 

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>             Fix For: 3.0.3
>
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MNG-5000) child distributionManagment.site.url not correct in a flat directory layout

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=255938#action_255938 ] 

Stefan Hansel commented on MNG-5000:
------------------------------------

Please don't just close this bug.

There is an issue with the site-plugin under Maven3 creating different pathes based on the artifact-ID of a module.
The site-plugin developers claim this is a core issue.

As someone from the outside I cannot decide if this is a site-plugin problem (where I originally filed the bug) or a core issue. But seeing this bug moved from one project to the other and then seeing it closed is no solution.

Regardless of who's right or wrong regarding the expected final directory layout: one of both modules is behaving wrong under Maven3.

Please compare the distribution.url (copied from help:effective-pom) of module1 and module2 with Maven3.

{code}
    <distributionManagement>
      <site>
        <id>MSITE-227</id>
        <url>file:///tmp/module1/</url>
      </site>
    </distributionManagement>
{code}
{code}
    <distributionManagement>
      <site>
        <id>MSITE-227</id>
        <url>file:///tmp/MSITE-227/module-2/</url>
      </site>
    </distributionManagement>
{code}

Here module1 adheres to the flat layout, while module2 uses a nested layout.
So if flat-layout is the expected one, then module2 is behaving wrong!

Please reconsider closing this bug (or at least move it back to the site-plugin of you don't think it's a core issue).


> child distributionManagment.site.url not correct in a flat directory layout
> ---------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Moved: (MNG-5000) child distributionManagment.site.url not correct in a flat directory layout

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukas Theussl moved MSITE-548 to MNG-5000:
------------------------------------------

           Complexity: Intermediate
    Affects Version/s:     (was: 3.0-beta-3)
                       3.0.2
                  Key: MNG-5000  (was: MSITE-548)
              Project: Maven 2 & 3  (was: Maven 2.x and 3.x Site Plugin)

> child distributionManagment.site.url not correct in a flat directory layout
> ---------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benjamin Bentmann updated MNG-5000:
-----------------------------------

    Summary: [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name  (was: child distributionManagment.site.url not correct in a flat directory layout)

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (MNG-5000) child distributionManagment.site.url not correct in a flat directory layout

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benjamin Bentmann closed MNG-5000.
----------------------------------

    Resolution: Not A Bug
      Assignee: Benjamin Bentmann

bq. (ie modules get deployed to the same level)

Which is the expected behavior as per MNG-3134 and the structure of the example project.

bq. [...] running help:effective-pom in one of the modules shows that the effective distributionManagement.site.url of the module is actually /tmp/module1, this is what the site plugin uses.

This is what I see with Maven 3.0.x
{code:xml}
<distributionManagement>
  <site>
    <id>MSITE-227</id>
    <url>file:///tmp/module1/</url>
  </site>
</distributionManagement>
{code}
and with Maven 2.2.1:
{code:xml}
<distributionManagement>
  <site>
    <id>MSITE-227</id>
    <url>file:///tmp/module1</url>
  </site>
</distributionManagement>
{code}
which apart from the trailing slash from the parent's URL being preserved by Maven 3.x, is identical. So I don't see how this is a core issue.

> child distributionManagment.site.url not correct in a flat directory layout
> ---------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-548) site:deploy -> folder structure is different when artifactId=module's directory

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-548?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253677#action_253677 ] 

Lukas Theussl commented on MSITE-548:
-------------------------------------

There are several issues here. First I cannot quite reproduce your problem (running maven 2.2.1, site-plugin-2.3-SNAPSHOT): the deployed directory structure is

root
module1
module-2

(ie modules get deployed to the same level) while it should actually be

root
root/module1
root/module-2

However, this is apparently not a site-plugin issue, running help:effective-pom in one of the modules shows that the effective distributionManagement.site.url of the module is actually /tmp/module1, this is what the site plugin uses.

Anyway, for such non-standard project layouts I would recommend to specify the distMngmnt sections for each module explicitly, doing so the deployed site is ok AFAICS.

> site:deploy -> folder structure is different when artifactId=module's directory
> -------------------------------------------------------------------------------
>
>                 Key: MSITE-548
>                 URL: http://jira.codehaus.org/browse/MSITE-548
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>    Affects Versions: 3.0-beta-3
>         Environment: windows
>            Reporter: Stefan Hansel
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Closed: (MNG-5000) [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name

Posted by "Benjamin Bentmann (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-5000?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benjamin Bentmann closed MNG-5000.
----------------------------------

       Resolution: Fixed
    Fix Version/s: 3.0.3

> [regression] child distributionManagment.site.url not correct in a flat directory layout when child's artifactId doesn't match its module name
> ----------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-5000
>                 URL: http://jira.codehaus.org/browse/MNG-5000
>             Project: Maven 2 & 3
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>            Assignee: Benjamin Bentmann
>             Fix For: 3.0.3
>
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-548) child distributionManagment.site.url not correct in a flat directory layout

Posted by "Lukas Theussl (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-548?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukas Theussl updated MSITE-548:
--------------------------------

    Summary: child distributionManagment.site.url not correct in a flat directory layout  (was: site:deploy -> folder structure is different when artifactId=module's directory)

> child distributionManagment.site.url not correct in a flat directory layout
> ---------------------------------------------------------------------------
>
>                 Key: MSITE-548
>                 URL: http://jira.codehaus.org/browse/MSITE-548
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>    Affects Versions: 3.0.2
>         Environment: windows
>            Reporter: Stefan Hansel
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (MSITE-548) site:deploy -> folder structure is different when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MSITE-548?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Stefan Hansel updated MSITE-548:
--------------------------------

    Attachment: artifact-id-testcase.zip

> site:deploy -> folder structure is different when artifactId=module's directory
> -------------------------------------------------------------------------------
>
>                 Key: MSITE-548
>                 URL: http://jira.codehaus.org/browse/MSITE-548
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>    Affects Versions: 3.0-beta-3
>         Environment: windows
>            Reporter: Stefan Hansel
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (MSITE-548) site:deploy -> folder structure is different when artifactId=module's directory

Posted by "Stefan Hansel (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MSITE-548?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253693#action_253693 ] 

Stefan Hansel commented on MSITE-548:
-------------------------------------

Ok, checked again - it indeed only happens with maven3.0.1 + 3.0.2 .
Who whould be responsible for such a bug-report? Is this the core of Maven http://jira.codehaus.org/browse/MNG ?

As you say 'non-standard project layout' - I thought that a flat multimodule project is completely valid (at least officially documented in the sonartype docs) and the best way to cope with eclipse, as it only knows a flat project structure anyway?

One other question: I already tried to manipulate/tweak the distributionManagement.site.url (but of course don't want to use absolute paths there).

I hoped that 
{code}
  <distributionManagement>
    <site>
      <url>${project.parent.distributionManagement.site.url}/subdir</url>
    </site>
  </distributionManagement>
{code}
would help in the submodule, but I only get errors and it looks like the variable is not resolved.
Any suggestions?



> site:deploy -> folder structure is different when artifactId=module's directory
> -------------------------------------------------------------------------------
>
>                 Key: MSITE-548
>                 URL: http://jira.codehaus.org/browse/MSITE-548
>             Project: Maven 2.x and 3.x Site Plugin
>          Issue Type: Bug
>    Affects Versions: 3.0-beta-3
>         Environment: windows
>            Reporter: Stefan Hansel
>         Attachments: artifact-id-testcase.zip
>
>
> There is a multimodule flat project structure:
> root
> module1
> module2
> module1 has an artifactID of 'module1'  (same as directory name)
> modulu2 has an artifactID of 'module-2' (different to directory name)
> After a 'mvn site-deploy' the generated report has the folder structure:
> /root
> /root/module-2
> /module1
> So based on the artifactID the submodules are created as a child of the root - or not.
> This is at least inconsistent and should be changed to be handled always the same - independent of the artifactID.
> This is also important for other plugins (i.e. the dashboard plugin).
> They seem to have some hardcoded directory structure (preferring submodules as childs of the root report). 
> Due to this bug (see http://jira.codehaus.org/browse/MOJO-1630) the links between reports there still don't work as long as artifactID=module's directory. 
> Attached you will find a testcase (based on maven3, but can also be used with maven2 when the version of the site-plugin is changed).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira