I have Hibernate entity that I have to convert to JSON, and I have to translate some values in entity, but when I translate values, these values are instantly saved to datab
I am also converting hibernate entities to JSON.
The bad thing when you close the session you cannot lazy load objects. For this reason you can use
hSession.setDefaultReadOnly(true);
and close the session after when you're done with the JSON.