You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Franz Allan Valencia See (JIRA)" <ji...@codehaus.org> on 2007/05/30 18:46:58 UTC

[jira] Created: (MRM-406) Replace the archiva.version propertry with project.version

Replace the archiva.version propertry with project.version
----------------------------------------------------------

                 Key: MRM-406
                 URL: http://jira.codehaus.org/browse/MRM-406
             Project: Archiva
          Issue Type: Improvement
    Affects Versions: 1.0-alpha-1
            Reporter: Franz Allan Valencia See


There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

Posted by "Joakim Erdfelt (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MRM-406?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_97833 ] 

Joakim Erdfelt commented on MRM-406:
------------------------------------

Mulling about this for a while. I see a third solution.

* Remove all <dependencyManagement> entries for archiva related modules/projects.
* Remove archiva.version property.
* Set <version> in all <dependencies> in all archiva modules/projects to project.version

It's the dependencyManagement fault that we are working around with the archiva.version property.


> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

Posted by "Joakim Erdfelt (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MRM-406?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_97696 ] 

Joakim Erdfelt commented on MRM-406:
------------------------------------

Try it yourself.

# Change from archiva.version to project.version
# When in trunk build the entire archiva - [trunk]$ mvn clean install
# Make a change to archiva-database.
#* This is key piece of showing this failure.
#* The change should be obvious, to show that archiva-database functionality has been updated.
# Now build just database - [trunk/archiva-database]$ mvn clean install
# Now execute the webapp - [trunk/archiva-web/archiva-webapp]$ mvn clean jetty:run

At this point you'll either get build failures, or when executing the webapp, you are *NOT* using the latest archiva-database.

What happens.
# The install process changes the SNAPSHOT in the pom to a TIMESTAMP(a).
# The installing everything works, as the TIMESTAMP(a)s are all the same.
# Installing the archiva-database project causes a new TIMESTAMP(b) to be created for it.
# Running the archiva-webapp, uses the parent-pom reference as SNAPSHOT, which resolves to TIMESTAMP(a), and as such, the archiva-database it uses is the old TIMESTAMP(a) version, not the intended TIMESTAMP(b) version.

This is a *well known* issue with maven.

We've hit this with redback too.  It uses the same technique.  I can't speak for continuum.

I contend that this is *not* and issue with archiva, but an issue with the maven-release-plugin, for not performing the updates to the versions correctly.

Solution:
# Fix the maven-release-plugin to do version updates correctly.



> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

Posted by "Joakim Erdfelt (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRM-406?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Joakim Erdfelt closed MRM-406.
------------------------------

    Resolution: Fixed

Fixed in trunk.
Changed archiva.version to fully expanded version id.

> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

Posted by "Franz Allan Valencia See (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRM-406?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Franz Allan Valencia See reopened MRM-406:
------------------------------------------


I am reopening this because archiva.version fails the release. A solution must be found such that there are no problems for both releasing and building.

> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

Posted by "Franz Allan Valencia See (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRM-406?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Franz Allan Valencia See updated MRM-406:
-----------------------------------------

    Attachment: MRM-406-archiva-parent.patch

> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

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

Brett Porter commented on MRM-406:
----------------------------------

Joakim - I don't think your 'each and every time' comment is correct, I can only see this happening if you are using snapshots from the web (since it might mistakenly use the snapshot version across the board instead of the -SNAPSHOT). Though I've never actually seen that happen either.

Seems like a bug that should be fixed in Maven rather than using this workaround, so I agree with the patch at this stage.

> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

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

Brett Porter commented on MRM-406:
----------------------------------

I tried steps 1 - 5 and I got the correct archiva-database (I did a diff to confirm).

The install process does not change the SNAPSHOT in the POM into a TIMESTAMP. Only the deploy process does, and then only remotely. You'll only get that locally when it is downloaded from the server again.

I believe you've seen it with redback because you regularly deployed and used those depoyed snapshots. I didn't dispute that would be a problem. It's something that should be fixed in Maven.

I believe the release plugin has work under way to dereference the expressions so that it can fix the properties that hold versions too (though this is a hairy issue and not one that should be considered a best practice).

I just believe that given all these circumstances, using ${project.version} was the least harmful. The redback release process got bitten by the fact that it wasn't updated more than once.

But I'm also not the one releasing it, so as long as it's documented either way, I don't care what it's set to.

> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

Posted by "Joakim Erdfelt (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MRM-406?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Joakim Erdfelt closed MRM-406.
------------------------------

         Assignee: Joakim Erdfelt
       Resolution: Won't Fix
    Fix Version/s: 1.0-alpha-1

Will not fix or patch.

Changing to project.version will cause SNAPSHOT based builds to fail.

The only way for a SNAPSHOT based build, based on project.version, will work is if you build the entire project each and every time, which is unrealistic in development time.


> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

-- 
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: (MRM-406) Replace the archiva.version propertry with project.version

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

Brett Porter commented on MRM-406:
----------------------------------

good idea. Let the release plugin take care of updating it.

actually, even if we just populate the versions in dependency management instead of using ${project.version}, it should work - the release plugin does deal correctly with depMgmt.

> Replace the archiva.version propertry with project.version
> ----------------------------------------------------------
>
>                 Key: MRM-406
>                 URL: http://jira.codehaus.org/browse/MRM-406
>             Project: Archiva
>          Issue Type: Improvement
>    Affects Versions: 1.0-alpha-1
>            Reporter: Franz Allan Valencia See
>            Assignee: Joakim Erdfelt
>             Fix For: 1.0-alpha-1
>
>         Attachments: MRM-406-archiva-parent.patch
>
>
> There is no need for the archiva.version property in the pom because this can be represented by the project.version property. Furthermore this can cause problems when doing a release with continuum.

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