Maven and Eclipse, Top Eclipse Kepler Feature #5

June 17, 2013 | 2 min Read

The Eclipse Kepler release is just over 1 week away, and to help celebrate the release I’m counting down the Top 10 Kepler Features I’m most excited about. Number 5 on my list is the much improved integration between Maven and Eclipse.

Integrating Maven based builds into Eclipse is not easy. This is because both Maven and Eclipse control the build process in fundamentally different ways. Eclipse uses an incremental compiler which runs each time a file is saved. Maven on the other hand is a very powerful build tool based on a variety of plug-ins and build phases. The M2E project was started to help bridge this gap. To get tight integration between Maven and Eclipse, M2E relies on ‘connectors’, highly specialized tools which bridge the disconnect between Maven plug-ins and Eclipse.

With Kepler, the M2E-WTP project has reached its 1.0 release. M2E-WTP delivers a number of Maven-2-Eclipse connectors for use with the Web Tools Project and is one of the most downloaded Eclipse plug-ins with over 20,000 installs per month.

M2E-WTP has support for converting Eclipse projects to Maven JavaEE projects.

M2E provides dependency management support, and if you choose to download the Maven Central Index, you can search for dependencies right from your IDE:

And with WTP’s hot-deployment and M2E-WTP, you can experience continuous deployment as your work.

M2E-WTP also supports Dynamic Web-Resource Filtering. With this feature, you can add parameters to your source and configuration files. Whenever they are saved the plug-in is triggered. In this example, as you change your profile from “Production” to “Staging”, the Eclipse version dynamically changes from “Kepler” to “Luna”.

M2E-WTP also supports WAR overlay, allowing you to share resources by overlaying them at build time. For example, you can overlay the Jenkins war in your own project.

And finally, there are a number of other optional connectors you can install for things like JAX-RS, JPA and JSF. These are all available in the Eclipse Kepler repository.

[ Find more build tools and other goodies at our Eclipse Tools page. | Managing your Eclipse workspaces is easier with Yoxos. Get Yoxos now. ]

A big thanks to Fred Bricon for all his hard work on M2E-WTP and for helping me with the details.

For my Eclipse Top 10 and other Eclipse Tips & Tricks, follow me on Twitter.

Ian Bull

Ian Bull

Ian is an Eclipse committer and EclipseSource Distinguished Engineer with a passion for developer productivity.

He leads the J2V8 project and has served on several …