users@jta-spec.java.net

Re: Fwd: portable way to restore XAResources required

From: Jonathan Halliday <jonathan.halliday_at_redhat.com>
Date: Wed, 20 Jun 2012 16:23:55 +0100

On 06/20/2012 11:02 AM, Christian Romberg wrote:

> I suggest to mandate the following behavior for the transaction manager
> when writing it's log file:
>
> "If the XAResource was acquired via a JNDI named pool or the XAResource
> is serializable, the
> transaction manager might store the JNDI name, or the serialized
> XAResource in it's transaction
> log file. If the XAResource was not acquired via a JNDI named pool and
> is not serializable, an
> exception will be thrown".

JNDI names present some fun issues for distributed environments, or even
environments that changes over time. In practice they are more useful
for providing additional information to recovery and for diagnostic log
messages than for fully automated recovery. Extending XAResource or
tx.enlistResource to support them is useful but insufficient IMO. Object
serialization is far too slow to be attractive. An interface by which
XAResources may be registered with the TM for recovery use is
preferable, though getting something totally portable may require
changes to the JCA spec too.

Jonathan.

-- 
Registered in England and Wales under Company Registration No. 03798903 
Directors: Michael Cunningham (USA), Mark Hegarty (Ireland), Matt Parson
(USA), Charlie Peters (USA)