| I'm seeing the following error be thrown when the EntityTransaction is marked to rollback only and the LogicalConnection.physicalConnection is null. As per our discussion, we should ignore the EntityTransaction.rollback() if the LogicalConnection.physicalConnection.getAutoCommit() returns true. Seems to me that we should also ignore the rollback() call if LogicalConnection.physicalConnection is null, as it makes no sense to me, that we would get a new DB connection just to see if it's autocommit flag defaults to true.
org.hibernate.TransactionException: Unable to rollback against JDBC Connection [javatest.batch] at org.hibernate.resource.jdbc.internal.AbstractLogicalConnectionImplementor.rollback(AbstractLogicalConnectionImplementor.java:122) [javatest.batch] at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.rollback(JdbcResourceLocalTransactionCoordinatorImpl.java:286) [javatest.batch] at org.hibernate.engine.transaction.internal.TransactionImpl.rollback(TransactionImpl.java:125)
|