[ 
https://issues.apache.org/jira/browse/MNG-5821?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Karl Heinz Marbaise closed MNG-5821.
------------------------------------
       Resolution: Not A Problem
         Assignee: Karl Heinz Marbaise
    Fix Version/s:     (was: waiting-for-feedback)

So i have taken your example projects...So first if i try to build the 
{{bundle}} project which means i do {{mvn package}} in the bundle folder i got 
the following message:
{noformat}
~/ws-git/maven-bugs/MNG-5821/bundle (master)$ mvn package
[INFO] Scanning for projects...
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR]   The project test:child:1.0-SNAPSHOT 
(/Users/kama/ws-git/maven-bugs/MNG-5821/child/pom.xml) has 1 error
[ERROR]     Non-resolvable parent POM: Failure to find 
test:parent:pom:1.0-SNAPSHOT in 
http://localhost:8081/nexus/content/groups/public was cached in the local 
repository, resolution will not be reattempted until the update interval of 
nexus has elapsed or updates are forced and 'parent.relativePath' points at 
wrong local POM @ line 5, 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
{{noformat}}
The {{bundle pom}} has a module which is called {{child}}. The child module has 
a parent which Maven tries to resolve which is is not possible, cause it does 
not exist in the parent folder relative from {{bundle/../pom.xml}} which simply 
does not exist. The result is that Maven tries to solve the parent pom from 
remote repository which fails of course.
This brings me to the point that your error output is only an excerpt and not 
the full output...

Furthermore i have tested your sample project with 3.0.5, 3.1.1, 3.2.5 and 
3.3.3 and got the same error message (only in 3.3.3 the message has been 
changed a little bit).

So let us come to the point where maven looks for a parent..than a parent must 
be define as such which in your example is not the case, cause you have defined 
the {{parent}} as a module..which is something different. If you would like 
having a [real example take a look in this test 
project|https://github.com/khmarbaise/javaee/tree/master/service| which 
contains several module and for example the {{service}} module contains a 
parent information and for this this documentation is intended.

BTW: Testing with an old version like 3.0.3 does not make sense, cause on the 
release line 3.0 there exist an newer one which is 3.0.5. 

Based on the previous i will close the issue as not a bug. If you have an other 
opinion please reopen the issue with supplemental information.

> Documentation of the element parent.relativePath wrong in XSD
> -------------------------------------------------------------
>
>                 Key: MNG-5821
>                 URL: https://issues.apache.org/jira/browse/MNG-5821
>             Project: Maven
>          Issue Type: Documentation
>            Reporter: Arthur Bauer
>            Assignee: Karl Heinz Marbaise
>         Attachments: mvn-3.0.5.log, mvn-3.1.1.log, mvn-3.2.5.log, 
> mvn-3.3.3.log, test.zip
>
>
> The documentation of the element parent.relativePath in the XSD file seems to 
> be wrong or outdated. It says: 
> "Maven looks for the parent pom first in the reactor of currently building 
> projects, then in this location on the filesystem, then the local repository, 
> and lastly in the remote repo." 
> (Source: http://maven.apache.org/xsd/maven-4.0.0.xsd)
> But the actual documentation of maven says
> "Maven looks for the parent POM first in this location on the filesystem, 
> then the local repository, and lastly in the remote repo."
> (Source: 
> http://maven.apache.org/ref/3.0.3/maven-model/apidocs/org/apache/maven/model/Parent.html#getRelativePath%28%29)
> I have tested it on my local and I have seen the behavior as described in the 
> second source, i.e. maven does not look for the parent pom in the reactor of 
> currently building projects first.
> So this is pretty misleading. It is even more misleading for us, as we are 
> reading the documentation directly from eclipse, which loads it from the XSD 
> file.
> Could you please correct the XSD documentation?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to