Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Later
-
None
-
None
Description
The XAResource interface[1] defines the transaction timeout to be a property of the resource itself, and not tied to any particular XID. In AMQP 0-10 however the DtxSetTimeout method is for a specific XID. At present org.apache.qpid.client.XAResourceImpl records the XID currently associated with the resource instance and uses that to implement get-/set- TransactionTimeout(). There are a couple of issues with this approach:
(a) the associated xid is not nulled on committing the transaction, meaning that a call to setTransactionTimeout() immediately after a commit() will result in a request to the broker to set the timeout on that xid which violates the AMQP 0-10 protocol
(b) the timeout set by a call to setTransactionTimeout() will only have effect on the currently associated xid which seems to violate the XAResource interfaces contract