public class TransactionXaAdapter extends AbstractEnlistmentAdapter implements XAResource
CacheTransaction
and implementor of an XAResource
that will be called by tx manager on various tx stages.TMENDRSCAN, TMFAIL, TMJOIN, TMNOFLAGS, TMONEPHASE, TMRESUME, TMSTARTRSCAN, TMSUCCESS, TMSUSPEND, XA_OK, XA_RDONLY
Constructor and Description |
---|
TransactionXaAdapter(LocalXaTransaction localTransaction,
XaTransactionTable txTable) |
TransactionXaAdapter(XaTransactionTable txTable) |
Modifier and Type | Method and Description |
---|---|
void |
commit(Xid externalXid,
boolean isOnePhase)
Same comment as for
prepare(javax.transaction.xa.Xid) applies for commit. |
void |
end(Xid externalXid,
int i) |
boolean |
equals(Object o) |
void |
forget(Xid externalXid) |
LocalXaTransaction |
getLocalTransaction() |
int |
getTransactionTimeout() |
boolean |
isSameRM(XAResource xaResource)
the only situation in which it returns true is when the other xa resource pertains to the same cache, on
the same node.
|
int |
prepare(Xid externalXid)
This can be call for any transaction object.
|
Xid[] |
recover(int flag) |
void |
rollback(Xid externalXid)
Same comment as for
prepare(javax.transaction.xa.Xid) applies for commit. |
boolean |
setTransactionTimeout(int i) |
void |
start(Xid externalXid,
int i) |
String |
toString() |
hashCode
public TransactionXaAdapter(LocalXaTransaction localTransaction, XaTransactionTable txTable)
public TransactionXaAdapter(XaTransactionTable txTable)
public int prepare(Xid externalXid) throws XAException
prepare
in interface XAResource
XAException
public void commit(Xid externalXid, boolean isOnePhase) throws XAException
prepare(javax.transaction.xa.Xid)
applies for commit.commit
in interface XAResource
XAException
public void rollback(Xid externalXid) throws XAException
prepare(javax.transaction.xa.Xid)
applies for commit.rollback
in interface XAResource
XAException
public void start(Xid externalXid, int i) throws XAException
start
in interface XAResource
XAException
public void end(Xid externalXid, int i)
end
in interface XAResource
public void forget(Xid externalXid) throws XAException
forget
in interface XAResource
XAException
public int getTransactionTimeout()
getTransactionTimeout
in interface XAResource
public boolean isSameRM(XAResource xaResource)
isSameRM
in interface XAResource
public Xid[] recover(int flag)
recover
in interface XAResource
public boolean setTransactionTimeout(int i)
setTransactionTimeout
in interface XAResource
public LocalXaTransaction getLocalTransaction()
Copyright © 2021 JBoss by Red Hat. All rights reserved.