@Transactional(propagation = Propagation.REQUIRES_NEW)
804785Aug 2 2011 — edited Aug 3 2011Hi,
I have a current transaction going on.
In case I come across into an exception, I need to call another method which persists data. (I want it to be persisted no matter what!)
For that reason, I have called a new method from the exception marked as "@Transactional(propagation = Propagation.REQUIRES_NEW)".
But going through that method, flow gets hanged on a 'return query.getResultList();' statement.
I checked in the database at that point of time to find the concerned tables having a lock.
How do I get the persisting done and then continue with the original transaction?
Thanks in advance!