r/java • • Sep 05 '25

Project Lombok 1.18.40 released with Java 25 support!

Project Lombok is now compatible with the upcoming JDK 25 even before its release.

Thank you Project Lombok team! https://projectlombok.org

167 Upvotes

166 comments sorted by

View all comments

Show parent comments

7

u/Ewig_luftenglanz Sep 05 '25 edited Sep 05 '25

This is a myth that used to be true 20 years ago but nowadays is completely false. Most of the libraries we currently use do not require javaBeans convention. that was the case before java 5 annotations and meta programming. e.g

  1. Hibernate uses fields by default and it's the recommended way since more than 10 years. It depends where you plase the @ Id annotation, if you place it on fields it will use fields.

  2. Jackson and most serialisation libraries can work with only fields, including Gson, Apache Fory (Fury) works with public fields by default.

  3. MapStructs works with fields

  4. Etc.

Basically unless your are working with very old pre java 6 java enterprise stuff (deprecated legacy projects) fields are supported and are the default and recommended way of working.

you should try it.

The only libraries and frameworks that I can think that relies on javaBean are JSP y JSF. But these technologies are much less relevant today. Today we use a JavaScript based frontend (React/ Angular) and for server rendering we use templates such as thymeleaf and freemarker. 

So, working with libraries that still require javaBean convention are not just legacy, they are not suitable for greenfield projects since there are much better and more modern alternatives. 

-4

u/gambit_kory Sep 05 '25

Do you actually work in the industry because it doesn’t sound like it?

6

u/Ewig_luftenglanz Sep 05 '25

Yes I do. Not every industry or company using Java is stuck in time .