JDBCTransaction.isActive() should report false if jdbcContext.connection().isClosed()
-------------------------------------------------------------------------------------
Key: HHH-2190
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-2190
Project: Hibernate3
Type: Bug
Components: core
Reporter: Jeffrey Bennett
In error-handling routines, I use Transaction.isActive() to determine if it is
'safe' to perform Transaction.rollback().
If the Session has previously closed, Transaction.isActive() mis-reports that the
transaction is still alive when it is not.
I'll grant that the JavaDoc for isActive indicates it is the 'local
transaction', not the underlying transaction, but since there is no way to delve into
the underlying connection in the public API, that is really a cop-out. If you don't
like the idea of modifying the behavior of isActive(), how about exposing a 'public
Connection connection()' method that exposes the connection?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira