Saturday, August 1, 2009

Maven an opinion

The 5 minute tutorial for Maven is great and illustrates the ease of use for a simple project. If you are starting a new project you can have a build file up and running in minutes (really). The catch is that your directory structure needs to follow the Maven directory structure. With a non-trivia build routine the upgrade is going to be a multi-day effort (Google ant maven upgrade). I would need to get something tangible for this effort...which of course is the dependency management.

I can see the value of dependency management in an open source project, it fills the same need as yum, apt-get etc; where there are many more people compiling the project with many odd ball libraries lying around on these disparate systems. Having a very large project with multiple modules that must integrate together Maven would also be one solution. You could run your own repository that would then be shared among the projects. This central repository could then be managed and a general release could be made, QA'd and deployed independent of releases of the sub project. I really, however, don't see the value otherwise. External libraries should be documented with their versions and what they do. They should be placed under version control with the rest of the source code. This is really not hard to do for anything but the largest of projects. Having libraries change around without a careful understanding of what has changed would not satisfy most QA departments that I have ever worked with, and the external reliance on the maven repositories is not the same as putting them under version control.

My conclusion is that I would look at Maven for a new project because of it's easy of use to get up and going, potential other benefits that I have not yet seen, and lack of downside given it can make ant calls, but would not recommend moving to it from Ant due to the effort of upgrade.