[
https://issues.apache.org/jira/browse/MENFORCER-281?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
James Nord updated MENFORCER-281:
---------------------------------
Description:
Maven
[3.5.0|https://maven.apache.org/docs/3.5.0/release-notes.html#Overview_about_the_changes]
[introduced CI friendly
versions|https://maven.apache.org/maven-ci-friendly.html].
However when used with [multi module
project|https://maven.apache.org/maven-ci-friendly.html#Multi_Module_Setup] the
enforcer fails the build as it can not resolve the parent.
The bug is that the parent resolution of a module in the reactor is attempting
to use the untransposed version.
e.g.
{noformat}
INFO] --- maven-enforcer-plugin:3.0.0-M1:enforce (display-info) @ sub-module ---
[WARNING] Rule 1: org.apache.maven.plugins.enforcer.RequirePluginVersions
failed with message:
Failure to find com.acme.product:parent:pom:0.9.8-${revision}SNAPSHOT in
https://repo.acme.com/content/groups/all was cached in the local repository,
resolution will not be reattempted until the update interval of acme-internal
has elapsed or updates are forced
com.acme.product:parent:pom:0.9.8-${revision}SNAPSHOT
from the specified remote repositories:
acme-internal (https://repo.acme.com/content/groups/all, releases=true,
snapshots=true)
{noformat}
to reproduce create a new multi module project as per the linked page above.
Add the enforcer plugin and rule to the build
run {{mvn -Drevision=1.2.3-SNAPSHOT}} and watch the build fail.
was:
Maven
[3.5.0|https://maven.apache.org/docs/3.5.0/release-notes.html#Overview_about_the_changes]
[introduced CI firendly
versions|https://maven.apache.org/maven-ci-friendly.html].
However when used with [multi module
project|https://maven.apache.org/maven-ci-friendly.html#Multi_Module_Setup] the
enforcer fails the build as it can not resolve the parent.
The bug is that the parent resolution of a module in the reacot is attempting
to use the untransposed verrsion.
e.g.
{noformat}
INFO] --- maven-enforcer-plugin:3.0.0-M1:enforce (display-info) @ sub-module ---
[WARNING] Rule 1: org.apache.maven.plugins.enforcer.RequirePluginVersions
failed with message:
Failure to find com.acme.product:parent:pom:0.9.8-${revision}SNAPSHOT in
https://repo.acme.com/content/groups/all was cached in the local repository,
resolution will not be reattempted until the update interval of acme-internal
has elapsed or updates are forced
com.acme.product:parent:pom:0.9.8-${revision}SNAPSHOT
from the specified remote repositories:
acme-internal (https://repo.acme.com/content/groups/all, releases=true,
snapshots=true)
{noformat}
to reproduce create a new multi module project as per the linked page above.
Add the enforcer plugin and rule to the build
run {{mvn -Drevision=1.2.3-SNAPSHOT}} and watch the build fail.
> RequirePluginVersions broken with "CI Friendly versions"
> --------------------------------------------------------
>
> Key: MENFORCER-281
> URL: https://issues.apache.org/jira/browse/MENFORCER-281
> Project: Maven Enforcer Plugin
> Issue Type: Bug
> Components: Standard Rules
> Affects Versions: 1.4.1, 3.0.0-M1
> Reporter: James Nord
> Priority: Critical
>
> Maven
> [3.5.0|https://maven.apache.org/docs/3.5.0/release-notes.html#Overview_about_the_changes]
> [introduced CI friendly
> versions|https://maven.apache.org/maven-ci-friendly.html].
> However when used with [multi module
> project|https://maven.apache.org/maven-ci-friendly.html#Multi_Module_Setup]
> the enforcer fails the build as it can not resolve the parent.
> The bug is that the parent resolution of a module in the reactor is
> attempting to use the untransposed version.
> e.g.
> {noformat}
> INFO] --- maven-enforcer-plugin:3.0.0-M1:enforce (display-info) @ sub-module
> ---
> [WARNING] Rule 1: org.apache.maven.plugins.enforcer.RequirePluginVersions
> failed with message:
> Failure to find com.acme.product:parent:pom:0.9.8-${revision}SNAPSHOT in
> https://repo.acme.com/content/groups/all was cached in the local repository,
> resolution will not be reattempted until the update interval of acme-internal
> has elapsed or updates are forced
> com.acme.product:parent:pom:0.9.8-${revision}SNAPSHOT
> from the specified remote repositories:
> acme-internal (https://repo.acme.com/content/groups/all, releases=true,
> snapshots=true)
> {noformat}
> to reproduce create a new multi module project as per the linked page above.
> Add the enforcer plugin and rule to the build
> run {{mvn -Drevision=1.2.3-SNAPSHOT}} and watch the build fail.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)