You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Jean-Paul GUIGUI (JIRA)" <ji...@codehaus.org> on 2009/05/01 12:28:44 UTC

[jira] Created: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
-----------------------------------------------------------------------------------------------------------

                 Key: MRELEASE-444
                 URL: http://jira.codehaus.org/browse/MRELEASE-444
             Project: Maven 2.x Release Plugin
          Issue Type: Bug
          Components: prepare
    Affects Versions: 2.0-beta-8
         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
Java version: 1.6.0_12
OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"

            Reporter: Jean-Paul GUIGUI
         Attachments: test-maven.zip

In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml

Before release:prepare
Parent
 |-Module M1-SNAPSHOT
 |  |-Dependency to D1-SNAPSHOT
 |-Module M2-SNAPSHOT
    |-Dependency D2-SNAPSHOT
    |-Dependency to M1-SNAPSHOT

After release:prepare
Parent
 |-Module M1
 |  |-Dependency to D1-SNAPSHOT <== WRONG
 |-Module M2
    |-Dependency D2
    |-Dependency to M1

In attachment a project. To reproduce the bug:
mvn -f pom-dependency.xml clean install
mvn clean install
mvn release:prepare
cat test-maven-dependency2/pom.xml

Maybe related to bug MRELEASE 295


-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=185190#action_185190 ] 

Olivier Lamy commented on MRELEASE-444:
---------------------------------------

I understand some are not rewritten because they are not part of reactors 
{code}
mvn validate
.....

[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO] ------------------------------------------------------------------------
[INFO] Test Maven Parent ..................................... SUCCESS [0.000s]
[INFO] Test Maven Module 1 ................................... SUCCESS [0.000s]
[INFO] Test Maven Module 2 ................................... SUCCESS [0.000s]
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
{code}
So dependency1/2 are not part of the reactors, I don't know why we should change this poms.



> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brett Porter updated MRELEASE-444:
----------------------------------

    Fix Version/s: Backlog

> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Patrick Phelan (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=175247#action_175247 ] 

Patrick Phelan commented on MRELEASE-444:
-----------------------------------------

Seeing the exact same issue. The only workaround I can come up with is to move the inter-project dependencies up to the parent poms and manually control the snapshot and hardening of these before and after the release. Very inconvenient. 

> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Olivier Lamy (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Olivier Lamy closed MRELEASE-444.
---------------------------------

    Resolution: Won't Fix

> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brett Porter updated MRELEASE-444:
----------------------------------

    Fix Version/s:     (was: Backlog)

> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Jean-Paul GUIGUI (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jean-Paul GUIGUI reopened MRELEASE-444:
---------------------------------------


Hi Olivier,

Agree, the pom.xml of dependency1/2 should not be modified, they are external dependencies (sorry there was a cat on the invalid filename in my previous post)

But the pom.xml of test-maven-module1 should point to the release version of dependency1 not to the snapshot version of dependency1 (even if the external dependecy is not in the reactor). Moreover, it's inconsistent because the pom.xml of the test-maven-module2 is properly pointing to the release version of dependency2.
I run again this test case with latest mvn 2.2.0 version, I have exactly the same issue.

My understanding of the problem it that for a multi-module project if a sub-module module2 is depending on a sub-module module1 which are both in the reactor, only the direct dependencies of the module2 are updated by the release:prepare goal. The dependencies declared into module1 are left to SNAPSHOT.

Would appreciate if you can re-open this bug and raise its priority. We haven't find any workaround and we need to manually review each pom at each delivery.


> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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: (MRELEASE-444) Prepare in multi-module project update the snaphsot version to release version only in one of the submodule

Posted by "Brendan Lawlor (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MRELEASE-444?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=175249#action_175249 ] 

Brendan Lawlor commented on MRELEASE-444:
-----------------------------------------

yep - it's a pretty glaring error. Hard to see how it was missed. I wonder if there are particular circumstances in which it happens and others in which it doesn't.

> Prepare in multi-module project update the snaphsot version to release version only in one of the submodule
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: MRELEASE-444
>                 URL: http://jira.codehaus.org/browse/MRELEASE-444
>             Project: Maven 2.x Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.0-beta-8
>         Environment: Apache Maven 2.1.0 (r755702; 2009-03-19 04:10:27+0900)
> Java version: 1.6.0_12
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Jean-Paul GUIGUI
>         Attachments: test-maven.zip
>
>
> In the case of a multi module project in which a submodule M2 is depending on the submodule M1, only the snapshot dependency of the submodule M2 (for instance D1) will be changed to release by the goal release:prepare. The snapshot dependencies of submodule M1 (D2) will not be automatically set to release into the pom.xml
> Before release:prepare
> Parent
>  |-Module M1-SNAPSHOT
>  |  |-Dependency to D1-SNAPSHOT
>  |-Module M2-SNAPSHOT
>     |-Dependency D2-SNAPSHOT
>     |-Dependency to M1-SNAPSHOT
> After release:prepare
> Parent
>  |-Module M1
>  |  |-Dependency to D1-SNAPSHOT <== WRONG
>  |-Module M2
>     |-Dependency D2
>     |-Dependency to M1
> In attachment a project. To reproduce the bug:
> mvn -f pom-dependency.xml clean install
> mvn clean install
> mvn release:prepare
> cat test-maven-dependency2/pom.xml
> Maybe related to bug MRELEASE 295

-- 
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