Coach Thrasher
Maven hype
Okay, there's so much hype in the OSS space that I've just got to comment on Maven, why to use it, and why to not use it. Maven has been in development as an alternative build management tool for a while now. I've used it in jipCam to make dependency management easier. You can find many projects on souceforge that use Maven per the "built by Maven" logo on their homepages (this gets projects to passively market Maven via the logo - for free).
So what makes Maven special? Should you use it? My thoughts are yes, and no.
Yes you should use it if you want to allow easy java-package dependency management for your project. How does this work? You basically add an xmlns attribute to your Ant build.xml file, add a maven jar file to your ANT_HOME/lib, and then add an XML tag to your Ant build.xml to identify the package dependencies. See the jipCam build.xml for details. This allows users that 1) have Ant properly installed, 2) have Maven properly installed, and 3) want to build your project, to easily get all of the required packages for your project to build or run.
This is great because the old way to do this is to create a myproject-tools.zip that bundles all of your library dependencies. The *-tools.zip often has old versions of many libraries, and if you download and build N projects, you could have N versions, or N copies of the same library dependencies all over your disk taking up space, and aging like a bottle of Mad Dog 20/20. With Maven, all of the dependencies are downloaded to a local cache repository and all of your build projects SHARE the libraries in the repository. Maven has built-in library version management, so you can have multiple versions of the same library, but only ONE copy of each. Yay!
No you shouldn't use it if you have a complicated Ant build process, or Ant targets that perform utility functions like automating-testing, running system executables, or anything else. Maven can create jar and war files for web projects, but it uses an Ant-like target structure to duplicate Ant's functionality for complicated targets. Why do this? Ant works great. Keep it simple, IMHO projects should stay with Ant for these kinds of tasks.
Posted at 01:07PM Feb 19, 2006 by jason in Software | Comments[0]