News: Maven book chapter available
A chapter on managing projects with Maven from the "Professional Java Tools for Extreme Programming" book has been released. The chapter goes into details on setting up Maven, how to use it, and details of Jelly.
- Posted by: Warner Onstine
- Posted on: January 20 2005 12:26 EST
Download: Managing Projects with Maven.
- a bland chapter by The Industry Observer on January 21 2005 15:10 EST
- I'd love to write a book on Maven by Warner Onstine on January 21 2005 22:53 EST
- Disappointed by Evgeny Goldin on January 26 2005 16:52 EST
- Maven for Dummies - Quick Start Guide by Muthu Ramadoss on January 24 2005 01:49 EST
- http://ibiblio.org/maven doesn't respond by Evgeny Goldin on January 27 2005 03:28 EST
Read through the chapter.
Did not give any more information then I already had.
I was looking at information in terms of
2. Information on available plugins
3. How to extend Maven
But I haven't found any takers yet. This was meant as an introduction to Maven for those that had not been either exposed to it yet or weren't sure why they should use it instead of Ant.
Thanks for taking the time to read it though I do appreciate it. I'm hoping to get some more Maven tutorials on my site as time permits.
sounds interesting milind when do you plan to complete the plugins section ?
Have you considered making a comparison between different build tools such as ANT ?
Nice initiative keep it up.
i must say, this is probably the most comprehensive and well-organized maven resource to date. keep it up!
In my case authors failed miserably to deliver the goods - I still don't see
any example of what Maven can do that Ant can't (except using Jelly syntax
and site generation, as about managing project dependencies - I'd better do
it myself, thank you). The chapter brings the same examples of compiling the
sources, running the tests and creating the output files (oh, "artifacts") -
so what ?? If someone's trying to convince the reader that Maven is, in fact,
Ant++ - I think the examples should be more powerful. Otherwise, Maven makes an
impression of some Ant wrapper coming with tons of xml and properties files but
doing almost nothing useful of itself. If it's not the case then the chapter didn't
prove it (to me, at least).
"Defining Your Project Structure" made me laugh really, really loudly - what kind
of "structure" are you talking about ? Maven's files + src/java + src/test - I'll
be damned to bring Maven to help me with it !
Another point that usually annoys me in books is author's attempt to explain
readers how to unpack the archives, set environment variables in Windows
and the like ... kind of "type the command and press Enter". Come on - do you
*really* consider your readers to be that incapable ?
I still don't see any example of what Maven can do that Ant can'tNothing. All that can be done with Maven can be done using Ant. Actually, it IS mostly done using Ant, in Maven.
managing project dependencies - I'd better do it myself, thank youGood luck!
This is actually not so easy for everyone. It can be cumbersome for several reasons:
- binaries don't fit well in CVS
- many projects use unversioned jars (ex: commons-lang.jar): which one is it actually using? what if it changes?
- when using Ant only, you have to ship all dependant jars, as well as taskdefs (ex: junit, xdoclet, dbunit, junitdoclet, jmock,etc). This for every project.
At Apache/Jakarta, they don't allow GPL/LGPL jars to be stored in CVS. What to do? Direct users to each website to download jars from there, and check that they've done it? Put them in CVS anyway?
Maven stores them in one central place on your filesystem (system-wide or user-wide). They are downloaded from one (sometimes several) place(s). Your company may hold one repository for internal libs that you use all over the place.
If someone's trying to convince the reader that Maven is, in fact,Ant++ - I think the examples should be more powerful. Otherwise, Maven makes animpression of some Ant wrapper coming with tons of xml and properties files but doing almost nothing useful of itself.I'm not sure that anybody's trying to convince anyone that Maven is Ant++. Ant is a perfect build tool, which is why Maven uses it. Maven IS, in fact, a sort of Ant wrapper. A higher level Ant, or "meta-Ant", but certainly not Ant++.
You can see Maven as a set of generalized Ant files that you use for more than one project. Whenever you add behaviour to Maven (through plugins, for instance), it will be available to all your projects that use it. You don't have to update all your projects' build files.
In fact, when you look at it closely, many build files look the same (same targets, same property names, etc). Generalization is the logical step further.
Most projects will use 1 xml file (project.xml) and only that. This file describes your project, what it depends on, its file structure (where are sources, test sources, resource bundles,...), and other useful infos (mailing lists, cvs info, home page, etc.) If you need to change some build properties, use 1 properties file (project.properties). If you need to add custom behaviour or to adapt Maven's behaviour for your specific needs, add 1 xml file (maven.xml) in which you write Ant code which you wrap in "goal", "pregoal", or "postgoal".
I hope I clarified Ant/Maven relationships a bit!
PS: If you're a Linux user, you may see it as the difference between LFS (Linux From Scratch), in which you build everything using the holy "./configure && make && make install" trinity, and Gentoo, in which you "emerge" stuff, but this trinity is still used underneath to build the sources.
End 2 End Enterprise Development Weblog by Muthu Ramadoss
for a Quick Start Guide to MAVEN.
http://ibiblio.org/maven doesn't respond[ Go to top ]http://ibiblio.org/maven doesn't respond as of yesterday evening (too many people installed Maven ? :). I told ya - I'd better manage the dependencies by myself.