-
1. Re: feedback on JBAS-7195 (WrappedConnection.checkTransactionStatus throws exception when transaction is marked for roll back)
adrian.brock Feb 23, 2010 11:41 AM (in response to smarlow)I don't think you'll break anything, but you'll lose the early notification of the failure.
i.e. in a lot of cases you'll be doing useless work which won't fail until it becomes time to commit/rollback.
That's cpu and resources that could be used by something else.
Perhaps you could make it an option in the -ds.xml instead?
The check was added to avoid sql operations leaking into the next transaction because of a race with the tx timeout.
This won't happen if the transaction is just MARKED rolled back only. The transaction hasn't completed yet.
See JBAS-5080, the race goes something like:
a) Thread 1: start running a query
b) Thread 2: timeout -> roll back transaction, which ends the local jdbc transaction
c) Thread 1: original query now reaches the real connection which is in a new local jdbc transaction as far as the jdbc driver is concerned
(b) hasn't happened if the JTA transactions is marked rolled back only
-
2. Re: feedback on JBAS-7195 (WrappedConnection.checkTransactionStatus throws exception when transaction is marked for roll back)
smarlow Feb 23, 2010 8:24 PM (in response to adrian.brock)For trunk, I like the idea of an option in the -ds.xm. For AS 4.x/5.x, maybe that could be controlled by a system property (just to minimize the amount of code changes).
-
3. Re: feedback on JBAS-7195 (WrappedConnection.checkTransactionStatus throws exception when transaction is marked for roll back)
siddhupec Jun 3, 2010 12:17 PM (in response to smarlow)how did u set this value in the -ds.xml?
-
4. Re: feedback on JBAS-7195 (WrappedConnection.checkTransactionStatus throws exception when transaction is marked for roll back)
siddhupec Jun 3, 2010 12:18 PM (in response to adrian.brock)how to set this option in -ds.xml?