I have extended the EmptyInterceptor provided by hibernate to perform some logic on post flush. The overwritten post flush method is provided with an iterator. When I tried to iterate, I received ConcurrentModificationException So the problem is, the iterator becomes invalid because the collection is modified. When I analysed the code, StatefulPersistenceContext is the class where the map is manipulated.
So what could be the possible root cause of the issue. How we can avoid this exception.
Note: I am using the hibernate-core-4.2.13.Final.jar
|