logoalt Hacker News

Lombok Is Still Relevant in the Age of Java Records

14 points • by swaranga • last Thursday at 6:15 PM • 15 comments • view on HN

Comments

708145_ • today at 5:39 AM

Lombok was never relevant, and using Jackson’s or other frameworks’ undesirable runtime sorcery does not make Lombok any more sound.

Adding a pile of annotations throughout your codebase, often five stacked on top of one another, which generate behavior that is not locally visible, was never a sane trade-off for saving a little boilerplate.

rootsudo • today at 4:56 AM

I’ve always been curious as to why Indonesia islands have been the naming convention for this sort of software for a long time.

It’s also funny because there is true irl “dark magic” for Java, Lombok and Bali.

Also surprised there isn’t much mention of Bali in general.

Randgalt • last Thursday at 8:51 PM

Quality of life libraries like Lombok (or my library https://github.com/Randgalt/record-builder) are now anachronisms. Agents don’t need libraries to avoid writing getters, setters, etc. Lombok et al are for humans and the days of human coding are ending, sadly.

➕ show 2 replies
Lewton • today at 6:23 AM

Lombok fucking sucks

@requiredargs sucks, if you rearrange the order of two fields with the same type on a class you invisibly break the code. If you have multiple constructors (requiredargs, allargs) it makes tracing how they’re used using the built in tools of your IDE impossible

@builder fucking sucks, if there’s non-nullable fields and you don’t set them, at best you get a runtime exception. Builder pattern should take non-null args explicitly in the builder() method so when you add a new required field it doesn’t invisibly break code 8 modules away

Only good thing is indeed the log annotation, and to some degree @getter @setter, big whoop

➕ show 2 replies
jen20 • today at 4:35 AM

This article does less to convince me that Lombok is worthwhile and more that Java (the language, not the JVM) is not.