javax.resource.spi
Interface XATerminator

All Known Subinterfaces:
JBossXATerminator (src)
All Known Implementing Classes:
TxManager (src)

public interface XATerminator

Transaction completion and crash recovery


Method Summary
 void commit(Xid (src)  xid, boolean onePhase)
          Commit the transaction
 void forget(Xid (src)  xid)
          Forget the transaction
 int prepare(Xid (src)  xid)
          Prepare the transaction
 Xid (src) [] recover(int flag)
          Retrieve xids that are recoverable
 void rollback(Xid (src)  xid)
          Rollback the transaction
 

Method Detail

commit

public void commit(Xid (src)  xid,
                   boolean onePhase)
            throws XAException (src) 
Commit the transaction

Parameters:
xid - the xid
onePhase - true for one phase commit, false for two phase
Throws:
XAException (src) - for an error

forget

public void forget(Xid (src)  xid)
            throws XAException (src) 
Forget the transaction

Parameters:
xid - the xid
Throws:
XAException (src) - for an error

prepare

public int prepare(Xid (src)  xid)
            throws XAException (src) 
Prepare the transaction

Parameters:
xid - the xid
Returns:
Either XA_RDONLY or XA_OK
Throws:
XAException (src) - for an error

rollback

public void rollback(Xid (src)  xid)
              throws XAException (src) 
Rollback the transaction

Parameters:
xid - the xid
Throws:
XAException (src) - for an error

recover

public Xid (src) [] recover(int flag)
              throws XAException (src) 
Retrieve xids that are recoverable

Parameters:
flag - the recovery option
Throws:
XAException (src) - for an error