Building Mule 2 with Maven 3

For the project I was working on, I wanted to try out the Mule ebMS adapter written by Clockwork. This adapter needs Mule 2, but unfortunately some of the dependencies for the latest release of Mule 2 (2.2.1) seem to have vanished from the popular Maven repositories.

No worries though, the Mule 2.2 source is not dead yet! Looking into their subversion repository you will find newer tags, so I checked out the latest tag, 2.2.8, and tried to build it – only to get a build failure.
I was using Maven 3, but Mule 2 was written for Maven 2. Not wanting to install an older version of Maven, I set out to fix the problem. Turned out there were actually two:
Firstly, Maven 3 does not want you to use values directly in the <includes> element, not even if it is a single value instead of a comma-separated list. Rather, you should use the child <include> element.
Secondly, the gmaven-plugin version used by Mule does not play nice with Maven 3. Upgrading to the latest version (1.4) fixed that.

This one was not all that hard to solve in the end, but it took a lot of googling and experimenting. I hope I will save you that trouble!

About Maven

I have nothing against Maven. It’s just that I sometimes don’t see the point.

Waiting for what?

I started on a Confluence plugin today. Of course I followed the instructions on the Atlassian website… after a while. I ordered mvn to eclipse:eclipse and… I had to wait for an hour. 574 (!) jar files later I could start doing what I planned to have finished already. Why would I have to wait to start coding on an example plugin for an hour?


What is wrong with a plugin-blank.tar.gz? Just a simple archive with all the stuff you need. All the jar dependencies, a working example doing… well nothing much. And last, but not least a build file (ant will do).

  1. Do not read any instructions
  2. Download and unpack
  3. code
  4. run ant

I would like to encourage companies like Atlassian to not go the Maven route… only. There is nothing wrong with having a simple example tar file available for the impatient.