preFlush « Interceptor « JPA Q&A





1. Interceptor preFlush    forum.hibernate.org

Hi all, I have been experimenting with the Interceptor interface trying to get some work done on my persistence entities after an update/save. I am mainly using postFlush to get the state of my entities and record that state somewhere else in my application (a requirement). Now, when I try to get the state of my entity in postFlush, I get ...

2. Interceptor.preFlush    forum.hibernate.org

I have questions about preFlush: 1. What does the interator iterate? The javadocs do not specify what "entities.next()" will return. I'm assuming it iterates through all known persistent instances returned from the session? 2. Can I modify the entities in preFlush? 3. Is preFlush called before dirty checking? In other words, if I modify entities in preFlush, will those changes be ...