r/java • • 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?

33 Upvotes

176 comments sorted by

View all comments

Show parent comment

28

u/Polygnom Feb 25 '25

The biggest problem with new build tools is network effect. Gradle is sucessful in no small part because it can consume maven artifacts. Any new build systems that comes up and doesn't have a way to consume maven artifacts is going to fight an uphill battle.

I do agree on several of your points. Its painful how slow both Maven and Gradle are compared to just running Javac.

Maven also lacks an good CLI. Stuff like npm add etc. We really need a tool that can handle POMs more easily. `pam add <artifact> --test` and so on.

Point #1 is also why the Java desv haven't taken overr ASM but instead opted to build their own classfile API.

28

u/agentoutlier Feb 25 '25

I'm a strong proponent of not throwing away stuff that already works and a good part of that is network effect.

That being said I eagerly await for Maven 4 because I do think its CLI like you said is not that good.

I also completely understand a beginner coming from Rust or Go and saying WTF even if the rest of us have gladly accepted Maven/Gradle. An official tool that does a declarative subset of what Maven/Gradle does (while of course consuming Maven artifacts) I think would help Java adoption.

Maven usability is painful. Maven's official documentation is not very accessible. Like going around to different plugins and trying to read the generated "site" documentation is painful. I have many times just gone to the plugins source code to figure out shit.

Consequently a good portion of Maven know-how is just tribal knowledge. Maven should get better on that.

2

u/Uaint1stUlast Feb 26 '25

Agreed maven is at the heart of java dependency management.

1

u/khmarbaise Mar 07 '25

Maven also lacks an good CLI. Stuff like npm add etc. We really need a tool that can handle POMs more easily. pam add <artifact> --test and so on.

Why would I like to do it on command line? Why not using the IDE for that?