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-Pierre Froud (JIRA)" <ji...@codehaus.org> on 2014/05/02 08:37:10 UTC

[jira] (MENFORCER-190) Rule to guarantee that the newest released version of an artifact will be used.

    [ https://jira.codehaus.org/browse/MENFORCER-190?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=345664#comment-345664 ] 

Jean-Pierre Froud commented on MENFORCER-190:
---------------------------------------------

This rule can be very useful here. Teams are working on many maven projects and, at the end, these projects are dependencies of a maven EAR project. 

There's a pom project that contains essentially a {{dependencyManagement}} section. This pom's goal is to describe the latest tested release versions that will go to the EAR project. And this pom is also used by the projects to describe the versions to use.

This rule would help to avoid problems like:

{{ProjectA}} latest good release version is 2.0 (breaks compatibility with previous 1.2 version), thus version 2.0 of {{ProjectA}} is added to the project describing versions (let's call it {{versionsPom}})

{{ProjectB}} needs {{ProjectA}}. {{ProjectB}} is currently using 1.2 version of ProjectA. It means {{ProjectB}} isn't using the latest version of {{versionsPom}}.
{{ProjectB}} will release a version using a version of {{ProjectA}} which is incompatible with the version of {{ProjectA}} that will be in the final EAR.

[Versions Maven Plugin|http://mojo.codehaus.org/versions-maven-plugin/] is a manual solution, an enforcer rule would be much better.

> Rule to guarantee that the newest released version of an artifact will be used.
> -------------------------------------------------------------------------------
>
>                 Key: MENFORCER-190
>                 URL: https://jira.codehaus.org/browse/MENFORCER-190
>             Project: Maven Enforcer Plugin
>          Issue Type: Improvement
>          Components: Standard Rules
>    Affects Versions: 1.3.1
>            Reporter: Karl-Heinz Marbaise
>            Priority: Minor
>
> It would be nice having a rule which guarantees having always the newest release of the project dependencies.
> It would also handy having a configuration option to limit this to a particluar groupId/artifactId (may be wildcards)...
> {code}
> <requireNewestReleasedVersion>
>   <transitive>true</transitive>
>   <includes>
>     <include>groupid:artifactId:*:bin:*</include>
>  </includes>
> </requireNewestReleasedVersion>
> {code}



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)