Search code examples
javaeclipsemaven-2log4jm2eclipse

Why does M2Eclipse complain about missing artifact when mvn command line doesn't?


I've just set up a brand new installation of Eclipse Helios and have configured M2Eclipse to use an external (v 2.2.1) installation of Maven.

The system compiles fine on the command line, but from within M2Eclipse several of my project modules have an error:

Missing artifact javax.jms:jms:jar:1.1:test

I can get past the error by excluding the jms artifact from the Atomikos dependencies. But my main question is how can the two provide different results!

Even more odd is that I have another installation of Eclipse Helios and everything works fine.


Solution

  • The dependency resolver in m2eclipse is not using the external Maven installation, it has to use the embedded Maven version. So, I'd recommend to get the latest version of m2eclipse, as well as Maven 3.x version to minimize the difference in dependency resolution.