Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Mvn install failure due to improper parent pom

 
avinash sudh
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i am getting the following error when i try to install the "Apache camel oauth tutorial" project(which is at http://camel.apache.org/tutorial-oauth.html). I have attached the pom.xml file. Please let me know what the issue is.

Scanning for projects...
The build could not read 1 project -> [Help 1]

The project org.apache.camel:camel-example-gauth:2.12-SNAPSHOT (C:\Users\avinashms\camel-example-gauth\pom.xml) has 1 error
Non-resolvable parent POM: Could not find artifact org.apache.camel:examples:pom:2.12-SNAPSHOT and 'parent.relativePath' points at wrong local POM @ line 22, column 13 -> [Help 2]
o see the full stack trace of the errors, re-run Maven with the -e switch.
e-run Maven using the -X switch to enable full debug logging.

or more information about the errors and possible solutions, please read the following articles:
Help 1] http://cwiki.apache.org/confluence/display/MAVEN/ProjectBuildingException
Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException
avinashms\camel-example-gauth>


Below is my pom.xml file :


 
Peter Johnson
author
Bartender
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The error indicates that Maven cannot find version 2.12-SNAPSHOT of the parent POM. And looking in Maven Central, the latest version of that POM is 2.11.0.

You have two choices for fixing this error:
a) You can change the version of the parent POM at line 25.
b) You can add a reference to the snapshot repository that contains version 2.12-SNAPSHOT.

Which you do depends on if your code needs new features that are available on in 2.12.
 
avinash sudh
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks a lot Peter. Could you please tell me the location of Maven central and how you figured out the version of parent pom?
 
Peter Johnson
author
Bartender
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maven Central is located at http://central.maven.org/maven2/
Be aware that if you go to that URL, you will be presented with a search page. If you want to use the browser to click through the artifact hierachy, you will need to add the first one or two parts of the groupId. For example, you might want to start by going to http://central.maven.org/maven2/org/apache and browse to "camel" from there.
 
avinash sudh
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Peter ... thank you for giving me the link to the Maven central
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic