public class OracleXAResource extends OracleXAResource
activeXid, canBeMigratablySuspended, connection, dblink, DEFAULT_XA_TIMEOUT, ORAISOLATIONMASK, ORATMREADONLY, ORATMREADWRITE, ORATMSERIALIZABLE, ORATRANSLOOSE, savedConnectionAutoCommit, savedXAConnectionAutoCommit, timeout, TMENDRSCAN, TMFAIL, TMJOIN, TMMIGRATE, TMNOFLAGS, TMNOMIGRATE, TMONEPHASE, TMPROMOTE, TMRESUME, TMSTARTRSCAN, TMSUCCESS, TMSUSPEND, XA_OK, xaconnection, xidHashXA_RDONLY| Constructor and Description |
|---|
OracleXAResource() |
OracleXAResource(Connection pm_conn, OracleXAConnection xaconn) |
| Modifier and Type | Method and Description |
|---|---|
void |
commit(Xid xid, boolean onePhase)
commit() -- Commit work done by global transaction specified by xid.
|
protected void |
doCommit(Xid xid, boolean onePhase) |
protected int |
doDoTwoPhaseAction(int nsites, int action, String[] dbnames, Xid[] xids) |
protected int |
doEnd(Xid xid, int flag, boolean isLocallySuspended) |
protected int |
doForget(Xid xid) |
protected int |
doPrepare(Xid xid) |
protected void |
doRollback(Xid xid) |
protected int |
doStart(Xid xid, int flag) |
void |
doTwoPhaseAction(int nsites, int action, String[] dbnames, Xid[] xids) |
void |
end(Xid xid, int flag)
end()-- End work performed on behalf of a transaction branch.
|
void |
forget(Xid xid)
forget() -- Tell RM to forget about a heuristically completed txn branch
|
int |
prepare(Xid xid)
prepare() -- Ask RM to prepare for a commit of the txn specified in xid.
|
void |
rollback(Xid xid)
rollback() -- Ask RM to roll back work done on behalf of a txn branch.
|
void |
start(Xid xid, int flag)
start() -- Starts work on behalf of a transaction branch.
|
allowGlobalTxnModeOnly, checkError, checkError, checkError, checkError, createOrUpdateXid, debug, enterGlobalTxnMode, exitGlobalTxnMode, getConnectionDuringExceptionHandling, getTransactionTimeout, isOnStack, isSameRM, isXidListEmpty, isXidSuspended, recover, removeXidFromList, restoreAutoCommitModeForGlobalTransaction, resumeStacked, saveAndAlterAutoCommitModeForGlobalTransaction, setTransactionTimeout, suspendStacked, updateXidListpublic OracleXAResource()
public OracleXAResource(Connection pm_conn, OracleXAConnection xaconn) throws XAException
XAExceptionpublic void start(Xid xid, int flag) throws XAException
start in interface XAResourcestart in class OracleXAResourcexid - A global transaction identifier.flag - One of TMNOFLAGS, TMJOIN, TMNOMIGRATE or TMRESUME.XAException - An error has occurred. Possible exceptions are XA_RB, XAER_RMERR, XAER_RMFAIL, XAER_DUPID, XAER_OUTSIDE, XAER_NOTA, XAER_INVAL, or XAER_PROTO.protected int doStart(Xid xid, int flag) throws XAException, SQLException
XAExceptionSQLExceptionpublic void end(Xid xid, int flag) throws XAException
end in interface XAResourceend in class OracleXAResourcexid - A global transaction identifier that is the same as what was used previously in the start method.flag - One of TMSUCCESS, TMFAIL, or TMSUSPEND.XAException - An error has occurred. Possible XAException values are XAER_RMERR, XAER_RMFAILED, XAER_NOTA, XAER_INVAL, XAER_PROTO, or XA_RB.protected int doEnd(Xid xid, int flag, boolean isLocallySuspended) throws XAException, SQLException
XAExceptionSQLExceptionpublic void commit(Xid xid, boolean onePhase) throws XAException
commit in interface XAResourcecommit in class OracleXAResourcexid - A global transaction identifier.onePhase - If true, the RM should use a 1-phase commit protocol to commit the work done on behalf of xid.XAException - (An error has occurred.) Possible XAExceptions are XA_HEURHAZ, XA_HEURCOM, XA_HEURRB, XA_HEURMIX, XAER_RMERR, XAER_RMFAIL, XAER_NOTA, XAER_INVAL, or XAER_PROTO. If the resource manager did not commit the txn and the paramether onePhase is set to true, the RM may raise one of the XA_RB exceptions. Upon return, the RM has rolled back the branch's work and has released all held resources.protected void doCommit(Xid xid, boolean onePhase) throws XAException, SQLException
XAExceptionSQLExceptionpublic int prepare(Xid xid) throws XAException
prepare in interface XAResourceprepare in class OracleXAResourcexid - A global transaction identifier.XAException - (An error has occurred.) Possible exception values are: XA_RB, XAER_RMERR, XAER_RMFAIL, XAER_NOTA, XAER_INVAL, or XAER_PROTO.protected int doPrepare(Xid xid) throws XAException, SQLException
XAExceptionSQLExceptionpublic void forget(Xid xid) throws XAException
forget in interface XAResourceforget in class OracleXAResourcexid - A global transaction identifier.XAException - An error has occurred. Possible exception values are XAER_RMERR, XAER_RMFAIL, XAER_NOTA, XAER_INVAL, or XAER_PROTO.protected int doForget(Xid xid) throws XAException, SQLException
XAExceptionSQLExceptionpublic void rollback(Xid xid) throws XAException
rollback in interface XAResourcerollback in class OracleXAResourcexid - A global transaction identifier.XAException - An error has occurred.protected void doRollback(Xid xid) throws XAException, SQLException
XAExceptionSQLExceptionpublic void doTwoPhaseAction(int nsites,
int action,
String[] dbnames,
Xid[] xids)
throws XAException
XAExceptionprotected int doDoTwoPhaseAction(int nsites,
int action,
String[] dbnames,
Xid[] xids)
throws XAException
XAException