aspose file tools*
The moose likes Ant, Maven and Other Build Tools and the fly likes Maven Error. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven Error." Watch "Maven Error." New topic
Author

Maven Error.

Gustavo Quandt
Greenhorn

Joined: Jul 16, 2012
Posts: 1
I'm having trouble compiling with maven.
It's saying that I don't have the repository files, but I have them all, and they're all configured in the right Path.
I don't know what's wrong.

Thanks



[Thumbnail for erromaven.jpg]

Peter Johnson
author
Bartender

Joined: May 14, 2008
Posts: 5836
    
    7

I can't find the Eclipse JARs you are referencing in Maven Central - I see older versions but not the versions you are referencing.

What remote repository have you configured?

You wrote that "they're all configured in the right Path". What do you mean by this? I assume you mean that they are all in the local repository on your PC. If that is what you mean, exactly how did you put the JARs into the loacl repository? It is not sufficient to copy the files there, you must install then using the "mvn install:install-file ..." command that Maven provides in the error message.

And by the way, please don't post screen shots! Instead, copy and paste the text form the command prompt window!


JBoss In Action
Gopi Chella
Ranch Hand

Joined: Apr 26, 2010
Posts: 53
Welcome to JavaRanch !!!

You are getting this maven build error because maven not able to get the jar files from repository, check your dependency details if those are correct then check your central repository url.

you should have central repository under repositories tag in pom.xml

<repository>
<id>maven.central</id>
<url>http://repo1.maven.org/maven2</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>


in case if the missing items(as per your logs) are doesn't have dependency then you should add snapshot in your pom.xml and also you need to add those snapshot into local repository.

you can add those into your local repository by check out those components and run locally.


SCJP 1.5
Karl Heinz Marbaise
Greenhorn

Joined: Aug 12, 2007
Posts: 19
Hi,

Gopi Chella wrote:you should have central repository under repositories tag in pom.xml

<repository>
<id>maven.central</id>
<url>http://repo1.maven.org/maven2</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>

Sorry but you shouldn't define repositories in the pom nor maven central, cause Maven already know about it.

The problem here is, there are used dependencies from Eclipse (equinox etc.) which are not in Maven Central available.

This can be read here: http://wiki.eclipse.org/EclipseLink/Maven

Furthermore to use Maven in real life it is really recommended to use a repository manager (Archiva, Artifactory or Nexus) which helps solving such problems in more comfortable way.

Kind regards
Karl-Heinz Marbaise

Software Configuration Management (Subversion, CVS, SVK etc.) http://www.skmwiki.de/
Subversion Repository Search Engine http://www.supose.org/
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Maven Error.