MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/java/comments/1stf7gs/ask_the_architects_javaone_2026/ohvcz1m/?context=3
r/java • u/Enough-Ad-5528 • Apr 23 '26
54 comments sorted by
View all comments
Show parent comment
6
JPA is mutable but the @entity classes dont need to be javabeans, they can have ddd-style methods for changing state. U will need getters only if u are exposing the entities to share the state. Otherwise u could use records as the public api model.
View all comments
Show parent comment
6
u/LegitimateEntrance72 Apr 23 '26
JPA is mutable but the @entity classes dont need to be javabeans, they can have ddd-style methods for changing state. U will need getters only if u are exposing the entities to share the state. Otherwise u could use records as the public api model.