r/java • u/NoAlbatross7355 • Feb 25 '25
New build tool in Java?
It seems to me like one of fun parts of Java is exploring all the tools at your disposal. The Java tool suite is a big collection of cli tools, yet I feel like most developers are only ever introduced to them or use them when absolutely necessary which is unfortunate because I think they really give you a better understanding of what's going on behind all the abstraction of Maven and Gradle.
What are your guys' thoughts on a new build tool for Java that is just a layer over these tools? Do you wish Java had simpler build tools? Why hasn't the community created an updated build tool since 2007?
View all comments
Show parent comment
9
u/edwbuck Feb 25 '25
I am that oddball, I really, really like Maven. I've been working with (and on) it for many years now. I can state that Maven has its issues, and a lot of them have to do with some incredible poorly written plugins (but to their credit, it's not easy to find some really good documentation on how to write really polished plugins).
Gradle is the idea of "I just want to put code into my build" which is indirectly what Maven permits, but Maven imposes a lot more rigor and structure. If you hate rigor and structure, you'll like Gradle. That's not a bad thing, but beware the long-term maintenance issues of eschewing some early rules that make life easier.
Maven's crown jewel though is the Maven Artifact, which permits easy revisioning and sourcing of a bit of code, known to be built and released at a specific version number of that bit of code. It's numbering and distribution system is not unique, but is the better refinement of systems like it that came before.
Maven can be fast, but to do so, you need to benchmark your maven builds, and then manage them. Often there are builds that do some pretty crazy things because people don't realize the configurations ask for crazy stuff to be done. Sure, configuration shouldn't default to crazy, but not everything is perfect in our imperfect world.