Atomikos Forum

suspend() not calling XAResource.end()

Hello,

We are trying to implement the JTA spec for Ehcache and found that a call to suspend() does not call XAResource.end(). Is there a reason why? It would help alot if that call was made, since the resource would be aware to the suspend call by the TM.

Thanks!

-Nabib
Nabib El-Rahman Send private email
Friday, February 19, 2010
 
 
Hi,

For maximum performance this is done 'lazily', i.e. only if the connection(s) are being used again after the suspend. In that case, we suspend the XAResource(s) involved. Otherwise, we do nothing and save a round-trip to the back-ends.

HTH
Guy Pardon Send private email
Saturday, February 20, 2010
 
 
Hi,

See my post for the suspend being called when needed by our connection pools.

As for explicit JTA/XA enlistment (via the API): the JTA spec is clear about this, it is the code that does the enlist (and suspend) that also needs to end the transaction context by delisting - whenever it suspends the transaction.

So this is _not_ up to the JTA implementation. If a JTA implementation does this than it is not compliant with the specs.

HTH

FYI: quoting section 3.2 of the JTA spec:

"The application server (ready: enlisting party) is responsible for ensuring that the resources in use by the application are properly delisted from the suspended transaction."
Guy Pardon Send private email
Tuesday, February 23, 2010
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics