HHH-4662 do not rollback when the exception occurs
git-svn-id: https://svn.jboss.org/repos/hibernate/core/trunk@18195 1b8cb986-b30d-0410-93ca-fae66ebed9b2
This commit is contained in:
parent
ba3639a25a
commit
3703d4c71c
|
@ -44,6 +44,7 @@ import javax.persistence.TransactionRequiredException;
|
|||
import javax.persistence.TypedQuery;
|
||||
import javax.persistence.PessimisticLockScope;
|
||||
import javax.persistence.LockTimeoutException;
|
||||
import javax.persistence.QueryTimeoutException;
|
||||
import javax.persistence.criteria.CriteriaQuery;
|
||||
import javax.persistence.criteria.CriteriaBuilder;
|
||||
import javax.persistence.metamodel.Metamodel;
|
||||
|
@ -809,6 +810,9 @@ public abstract class AbstractEntityManagerImpl implements HibernateEntityManage
|
|||
if ( e instanceof LockTimeoutException ) {
|
||||
return;
|
||||
}
|
||||
if ( e instanceof QueryTimeoutException ) {
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
markAsRollback();
|
||||
|
|
Loading…
Reference in New Issue