Consistent reset of resource holders on doBegin failure

Issue: SPR-12280
This commit is contained in:
Juergen Hoeller
2014-10-06 20:26:45 +02:00
parent 1e9e6c9f6b
commit e58b33a593
6 changed files with 29 additions and 16 deletions

View File

@@ -513,6 +513,7 @@ public class HibernateTransactionManager extends AbstractPlatformTransactionMana
}
finally {
SessionFactoryUtils.closeSession(session);
txObject.setSessionHolder(null);
}
}
throw new CannotCreateTransactionException("Could not open Hibernate Session for transaction", ex);