I have a hibernate entity called Execution. It is created in the beginning of my process and updated at end, indicating how it has finished.
I would like to update a single property of this entity, without causing a select in my database.
Execution execution = entityManager.getReference(Execution.class, executionId);
execution.setStatus(Status.FINISHED);
//--> Calling this method fires a SELECT in my Database. I didn't want it to happen, I just want to update my entity.
This is not specific to this method, any other method called results in a SELECT clause. In fact, the select appears to happen even before my method is called. My impression is that hibernate proxies put some code inside my class no-args contructor to fire a select everytime any method is called.
Is it possible to update JPA/Hibernate entities without firing a SELECT statement in my database?