I have a project in which the maven-enforcer rule crashes using a multi-module build using non-unique snapshots (which annoyingly only apply to a snapshot supported in Maven 3).
For example, suppose that → is a "depends on" relationship and:
- Module-A → Module-B → Module-C
- Module-A → Module-C
and that module B and module C are present in the snapshot store as unique assemblies. All announced versions of modules in POM are currently 1.0-SNAPSHOT.
Now the assembly module A fails:
mvn -pl Module-A install
leads to:
[INFO]
Transit dependency is allowed as not a unique assembly of snapshots, but direct dependence is allowed as a unique assembly of snapshots.
I am using maven 3.0.3, maven-enforcer 1.0.1. Artifactory 2.4.2 repository using a unique snapshot option (as recommended by Artifactory, since Maven 3 no longer supports non-unique snapshots).
Solutions?
Refresh . Looks like artifactory allows you to override the behavior of the maven client and save the unhistorical snapshot to the repository. However, for some reason, Artifactory does not recommend this (see "Maven 3" at http://wiki.jfrog.org/confluence/display/RTF/Local+Repositories ), so other solutions are still welcome.
Raman source share