Imagine a bacon-wrapped Ferrari. Still not better than our free technical reports.

The Ultimate Java Build Tool Comparison: Gradle, Maven, Ant + Ivy

The cost of a test

This time Maven seems to be fairly static on it’s timings compared to the previous run, but Gradle and Ant seem to have jumped ahead. We’re still looking at some very close times so again there’s nothing to split the pack here. Next we’re going to run tests as part of our build and see how the build tools fare. The first set of results below are with a clean, compile, package and test. The second set of results omits the clean stage.

java build tools part 2 the cost of test

Doing a clean build with tests (download dependencies)

Holy dependencies Batman! At last, something we can really go to town on! Ivy really struggles with it’s dependency downloads, in terms of speed. Maven and Gradle download dependencies one at a time, when they locate them. Ivy, however, has a two phase approach. It will try to find all it’s dependencies first and then it will start to download them all. This process takes a long time, but once all the dependencies have been pulled down, Ant takes over and zips through the build and test as quick we’ve seen above. It’s a real shame it is exposed so much during the dependency download phase.

java build tools part 2 doing a clean build with tests download dependencies

MAVEN

Java build tools part 2 clean build with tests download dependencies Maven score

GRADLE

Java Build Tools Part 2 report doing a clean build with tests download dependencies gradle

ANT + IVY*

java build tools part 2 clean build with tests download dependencies Ant + Ivy score

*Average taken of Ant (5) and Ivy (2)

COMMENTS:
Maven and Gradle are close enough to Ant for it’s build, and test differences not to matter so much. Ivy loses points here for it’s shocking lack of speed on dependency downloads. Nobody gets 5 here, as there’s always room for improvement with build speed!


DOWNLOAD THE PDF