Description
The following exception is thrown when issuing multiple commits against a started transaction.
com.ibatis.common.jdbc.exception.NestedSQLException:
Could not commit transaction. Cause:
com.ibatis.sqlmap.engine.transaction.TransactionException:
TransactionManager could not commit. No transaction
is started.
The problem is that the TransactionManager is throwing this exception in all cases except when the Transaction State is STATE_STARTED. In this scenario, the transaction has been started, but its state is STATE_COMMITTED.
Clinton asked me to log this issue and attach my fix. The fix is in the TransactionManager.commit method and allows a commit to be performed if the Transaction state is either STATE_STARTED or STATE_COMMITTED.