commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oliver Zeigermann <oliver.zeigerm...@gmail.com>
Subject Re: [transaction] compatibility of ResourceManager to XAResource interface
Date Wed, 16 Nov 2005 15:35:06 GMT
They are all present as keys in

globalTransactions

after recovery which is done at startup automatically. It would be
very easy to add a method that simply returns an accumulated list of
them.

Oliver

2005/11/15, Joerg Heinicke <joerg.heinicke@gmx.de>:
> When following the JTA 1.0.1B spec [1] while implementing my resource adapter
> (XAResource) around the Commons Transaction FileResourceManager I came across
> another issue:
>
> XAResource has a method "public Xid[] recover(int flag)". Following is written
> in the spec's section "3.4.8 Failures recovery":
>
> "For each resource manager, the Transaction Manager uses the XAResource.recover
> method to retrieve the list of transactions that are currently in a prepared or
> heuristically completed state. [..] Because XAResource objects are not
> persistent across system failures, the Transaction Manager needs to have some
> way to acquire the XAResource objects that represent the resource managers which
> might have participated in the transactions prior to the system failure. For
> example, a Transaction Manager might, through the use of the JNDI lookup
> mechanism and cooperation from the application server, acquire an XAResource
> object representing each of the Resource Manager configured in the system. The
> Transaction Manager then invokes the XAResource.recover method to ask each
> resource manager to return any transactions that are currently in a prepared or
> heuristically completed state. It is the responsibility of the Transaction
> Manager to ignore transactions that do not belong to it."
>
> This means I need a way to retrieve a list of transaction IDs to be recovered,
> which the Commons Transaction ResourceManager interface does not provide at the
> moment. Its recover() method does not provide it. Would it be possible to change
> the method though this changes the interface?
>
> Jörg
>
> [1] http://java.sun.com/products/jta/index.html
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message