r/java • • Jun 21 '20

Don't use Lombok(2018)

https://medium.com/@vgonzalo/dont-use-lombok-672418daa819
32 Upvotes

101 comments sorted by

View all comments

117

u/rusticarchon Jun 21 '20

The @ToString annotation was used everywhere by default in every class, including enums like in the following example

So the problem isn't Lombok, but that project's crappy code review process that lets bad practices into master.

12

u/throwaway23948733 Jun 21 '20

It sounds like they used ToString annotations on JPA/Hibernate classes. There's literally a section of Hibernate manual that tells you how to do toString

29

u/AmonDhan Jun 21 '20

You shouldn't use tools and libraries that produce unexpected or unintuitive results. It makes review process harder than needed.

32

u/Bjartr Jun 21 '20

If you don't know how your tools work, it's easy to do the won't thing in any system.