Monday, January 08, 2007

Half a Year of Maven 2: An experience of the awkward kind

We're using Maven 2 now for all new projects. At the highest level I can summarize our experience as:
  1. The concepts behind Maven are sound and amazingly useful.
  2. The implementation is just about usable - no show-stoppers anymore, but lots and lots of little, annoying bugs and surprising gotchas
  3. The documentation is sloppy.
The really funny thing is, how point 1. still by far outweighs the shortcomings 2. and 3 when it comes to the question "Was it worth it, after all?".

So what made it useful, after all?
  • First of all, it gives your builds a uniformity and completeness (JavaDocs, HiveDocs, PMD, CPD, ...) that would be difficult to achieve otherwise without having a dedicated, organization-wide build-manager (as a real person:).
  • Secondly, it facilitates re-use by making doing the right things easier than the wrong ones. Having cleanly specified dependencies referring to specific binary versions of jars makes a bigger difference than you might think without trying. And being able to inherit a big part of your build-setup from an org-wide POM (the ant project descriptor) is a real killer feature. Together with archetypes this makes the overhead for starting a new library-module really negligable.
Enough praise. The downside is, there is still way enough room for maven-improvement wishes for the new year. Too many things just make - sorry - too sloppy an impression for a project which is purportedly backed by a professional org (Mergere). Some of the issues I remember are:
  • Docs: One of the benefits of Maven should be good consistent docs. Ever searched for reference docs on the site-descriptor site.xml? Google the mailing-lists. Wondering how to generate standard plugin-documentation? Don't bother with the docs. Just have a look at the POM's of existing modules. Looking for core API-docs? You'll find something like this
  • The SCM / release plugin claims to support DOS'ish CVS-pathes (D:\...) - in the report it works, but the release:prepare fails.
  • Special characters in the generated docs don't work. E.g. german locale.
  • Want to create a repo-bundle for a multi-module project? Doesn't work.
  • In a Mojo you can inject things into private fields - If a superclass happens to have a private field of the same name the injection fails silently.
So, after all, a great tool with a great amount of small issues to work on. Please, Maven guys, put some effort in finishing off the little bugs - and thanks for a useful tool.

Friday, January 05, 2007

New Version of hivedoc-plugin for HiveMind

Since some people seem to use it, I've updated my hivedoc-plugin to version 1.0.1 . Notable changes are:
  • Support for custom resource root directories
  • Backport to Java 1.4
  • proper plugin-docs
The new version should show up on the central Maven 2 repo soon. If you need it before that, here's the repo-bundle.

Tuesday, January 02, 2007

hivedoc-plugin generates Maven 2 docs for HiveMind descriptors

If you're using HiveMind and Maven 2, generating docs for your HiveMind descriptors is now really quick and simple.
Find the docs under http://marcus-schulte.ch/hivedoc-plugin/.