• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Maven Optimism
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Maven Optimism


  • Subject: Re: Maven Optimism
  • From: Lachlan Deck <email@hidden>
  • Date: Wed, 9 Jul 2008 12:13:17 +1000

On 09/07/2008, at 10:05 AM, Pierce T.Wetter III wrote:

<...>
So I thought I would post about my newfound optimism with Maven. I feel I owe it to Henrique and Lachlan for their help. (Thanks guys) I also think the current maven evangelism documentation is written a little too formally to be comprehensive.


<...>
To get started with Maven, I sat down with the Wonder sources, and tweaked the existing pom.xml files that had been broken since the great re-org to work. (pom.xml are the only and only type of file that Maven uses for building)

Not quite the only, but the primary. i.e., in many cases nothing else is needed - but it can be supplemented by profiles.xml, settings.xml, assemblies and so forth.


<...>
Jarmeggedon/jarhell

It seems like one of the greatest tools in a Java programmers arsenal is Google, or rather, 3rd party libraries. If you look at the Wonder source, there are 65 different .jar files included, about 1 per project on average. Many of these jar files are duplicates of each other, or even worse, different versions of the same jar, like there is a version of commons-logging.jar in ERJGroupsSynchronizer and another one in EROpenID. Meanwhile, commons-logging is up to version 1.1.1.

To be fair, this is not so much a problem with ant per-se. It just means that someone hasn't gone to the trouble of putting shared jars in a shared location and bundled with the app upon build. But certainly maven does help reduce redundancy (e.g., not having to declare a lib dependency both in ant + eclipse). Care needs to be taken with both systems of course to ensure that what you get in the build is what's expected. Andrus and Henrique have both commented on this.


To my way of thinking, the Wonder ant builds are already broken if EROpenID is building against commons-logging-1.03, but then deployed with 1.1.1...

Maven's solution goes by the fancy name of "dependency management". What that means in practice is that most of the information in the pom.xml is just a list of what other projects in your source tree a given project depends on, and what jars you need by name/version. In return, maven:

1. Finds and downloads any jars you're missing.

Naturally, not every jar in the world is available by default means. So defining additional repositories is sometimes needed (e.g., for woproject stuff).


<...>
I have a ways to go with my maven knowledge, but given that I was able to get Wonder building without really knowing that much about mvn, and without knowing all the ins-outs of the Wonder interelationships, I think that speaks well for Maven.

there's lots to learn for sure and there's lots of possibilities available (via plugins) which I like.


It's worth saying, however, "Don't throw caution to the wind". It's pretty cool, sure, but FWIW I'm still keeping my eyes and ears open given the experiences from both Henrique and Andrus - both of whom have been in the maven game longer than I.

with regards,
--

Lachlan Deck
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Maven Optimism (From: Pierce T.Wetter III <email@hidden>)

  • Prev by Date: Re: EOFetchSpecification text to number conversion
  • Next by Date: Re: Maven Optimism
  • Previous by thread: Maven Optimism
  • Next by thread: Re: Maven Optimism
  • Index(es):
    • Date
    • Thread