Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.0, 3.0.1
-
None
Description
Given the following two projects:
parent, released as organization POM
child, uses parent as its parent
parent pom is NOT in the local repository (i.e. new developer machine or build node of the CI)
settings.xml defines:
a) a global mirror for all repositories (http://local-nexus.srv/content/groups/public)
<mirrors> <mirror> <id>Nexus</id> <name>Coporate Nexus</name> <url>http://local-nexus.srv/content/groups/public</url> <mirrorOf>*</mirrorOf> </mirror> </mirrors>
b) a profile "repos" including a snapshot repository and an active-profiles entry activating this profile
<profiles> <profile> <id>repos</id> <repositories> <repository> <id>nexus-snapshots</id> <name>Projektserver Snapshots</name> <url>http://local-nexus.srv/content/repositories/snapshots</url> <releases> <enabled>false</enabled> </releases> <snapshots> <enabled>true</enabled> <checksumPolicy>fail</checksumPolicy> <updatePolicy>always</updatePolicy> </snapshots> </repository> </repositories> </profile> </profiles> <activeProfiles> <activeProfile>repos</activeProfile> </activeProfiles>
This is a fairly standard setup for copporate development.
now, when trying to compile the project, the following error is thrown:
[INFO] Scanning for projects... [ERROR] The build could not read 1 project -> [Help 1] [ERROR] [ERROR] The project de.eucodos.bugs.maven:child:0.1-SNAPSHOT (X:\ACM\test\child\pom.xml) has 1 error [ERROR] Non-resolvable parent POM: Could not find artifact de.eucodos.bugs.maven:parent:pom:0.1 and 'parent.relative Path' points at wrong local POM @ line 3, column 11 -> [Help 2] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException [ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
Without maven trying to download the parent from the corp-repo.
Sidenote: with Maven 2.x, this works without problems.
If an additional release-repository is included in profile "repos", everything works as expected:
<profiles> <profile> <id>repos</id> <repositories> <repository> <id>nexus</id> <name>Projektserver</name> <url>http://msgs722i.msg.de:8080/nexus/content/groups/public</url> <releases> <enabled>true</enabled> </releases> </repository> <repository> <id>nexus-snapshots</id> ...
Attachments
Attachments
Issue Links
- links to