Help

After gradually collecting more and more experience with Gradle via the Hibernate Core build, I decided prepare a final showdown. As a reminder, Hibernate ORM switched as of version 4 from Maven to Gradle for a variety of reasons. Taking these reasons on board, I tried to compare Maven vs Gradle incorporating some of the lessons learned. I presented the results at Jfokus 2012. If you are interested here are the slides[1].

Bottom line, if you are already using maven and have no issues or if you are building simple artifacts stick to Maven. If you have problems with things like:

  • Scripting
  • Rector builds
  • Assembly creation (release bundle creation)
  • (Javadocs) Aggregation
  • Grouping of dependencies

you might want to consider Gradle.

--Hardy

4 comments:
 
17. Feb 2012, 20:52 CET | Link
boniek

To me the worst mistake gradle makes is that it uses groovy exclusively AFAIK. I have nothing against groovy except that I don't know it, don't care about it and don't intend to learn it just to use a build tool. They should make groovy optional and make possible to use other scripting languages as well so we can reuse our expertise instead of learning things we don't really need and want to (a lot of people know javascript already for example). It would drastically lower barriers to entry.

ReplyQuote
 
17. Feb 2012, 21:11 CET | Link

I think you mean drastically raise barriers ;)

I knew nothing about Groovy when I started migrating Hibernate from Maven to Gradle. To say that it will drastically lower adoption is being a tad over-dramatic IMO. Will some people like yourself refuse to try/use it because they aren't familiar with Groovy? Sure. Will that be the majority of people? I doubt it.

Would it be nice if they exposed other scripting languages? Maybe. Sounds like a good feature request. Gradle itself is built using Groovy, so not sure how feasible that is going to be.

There is also SBT and Buildr. I have not looked at them since I did the initial migration and decided on Gradle. So I have not kept up. But even back then Gradle was IMO superior and it has only advanced very quickly.

 
22. Feb 2012, 08:40 CET | Link
Justin Ryan | jryan(AT)netflix.com
Learning Groovy isn't exactly relevant or a requirement, since Gradle provides a deep DSL. Meaning that the bulk of the basics specified in a build file would be barely recognizable as Groovy, e.g. applying a plugin and specifying dependencies. Any new tool comes with a language, and we should just be happy that this one isn't XML.
 
20. Apr 2012, 00:56 CET | Link

Hey, Hardy...

If you use the http://www.jfokus.com url it will get you to the English version of the Jfokus site.

Regards, Mattias Karlsson

Post Comment