java.lang.Object
org.omg.PortableServer.Servant
com.arjuna.ArjunaOTS.OTSAbstractRecordPOA
com.arjuna.ats.internal.jta.resources.jts.orbspecific.XAResourceRecord
All Implemented Interfaces:
ArjunaSubtranAwareResourceOperations, OTSAbstractRecordOperations, org.omg.CORBA.portable.InvokeHandler, ResourceOperations, SubtransactionAwareResourceOperations
Direct Known Subclasses:
LastResourceRecord, XARecoveryResourceImple, XAResourceRecordBean.JTSXAResourceRecordWrapper

public class XAResourceRecord extends OTSAbstractRecordPOA
  • Field Details

  • Constructor Details

    • XAResourceRecord

      public XAResourceRecord(TransactionImple tx, XAResource res, Xid xid, Object[] params)
      The params represent specific parameters we need to recreate the connection to the database in the event of a failure. If they're not set then recovery is out of our control. Could also use it to pass other information, such as the readonly flag.
    • XAResourceRecord

      public XAResourceRecord()
    • XAResourceRecord

      protected XAResourceRecord(Uid u)
  • Method Details

    • get_uid

      public final Uid get_uid()
    • getResource

      public final Resource getResource()
    • getXid

      public final Xid getXid()
    • prepare

      public Vote prepare() throws HeuristicMixed, HeuristicHazard, org.omg.CORBA.SystemException
      Throws:
      HeuristicMixed
      HeuristicHazard
      org.omg.CORBA.SystemException
    • rollback

      public void rollback() throws org.omg.CORBA.SystemException, HeuristicCommit, HeuristicMixed, HeuristicHazard
      Throws:
      org.omg.CORBA.SystemException
      HeuristicCommit
      HeuristicMixed
      HeuristicHazard
    • commit

      public void commit() throws org.omg.CORBA.SystemException, NotPrepared, HeuristicRollback, HeuristicMixed, HeuristicHazard
      Throws:
      org.omg.CORBA.SystemException
      NotPrepared
      HeuristicRollback
      HeuristicMixed
      HeuristicHazard
    • prepare_subtransaction

      public Vote prepare_subtransaction() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • commit_subtransaction

      public void commit_subtransaction(Coordinator parent) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • rollback_subtransaction

      public void rollback_subtransaction() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • type_id

      public int type_id() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • uid

      public String uid() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • propagateOnAbort

      public boolean propagateOnAbort() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • propagateOnCommit

      public boolean propagateOnCommit() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • saveRecord

      public boolean saveRecord() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • merge

      public void merge(OTSAbstractRecord record) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • alter

      public void alter(OTSAbstractRecord record) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • shouldAdd

      public boolean shouldAdd(OTSAbstractRecord record) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • shouldAlter

      public boolean shouldAlter(OTSAbstractRecord record) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • shouldMerge

      public boolean shouldMerge(OTSAbstractRecord record) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • shouldReplace

      public boolean shouldReplace(OTSAbstractRecord record) throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • notAProblem

      protected boolean notAProblem(XAException ex, boolean commit)
      Is the XAException a non-error when received in reply to commit or rollback? It normally is, but may be overridden in recovery.
    • commit_one_phase

      public void commit_one_phase() throws HeuristicHazard, org.omg.CORBA.SystemException
      For commit_one_phase we can do whatever we want since the transaction outcome is whatever we want. Therefore, we do not need to save any additional recoverable state, such as a reference to the transaction coordinator, since it will not have an intentions list anyway.
      Throws:
      HeuristicHazard
      org.omg.CORBA.SystemException
    • forget

      public void forget() throws org.omg.CORBA.SystemException
      Throws:
      org.omg.CORBA.SystemException
    • isForgotten

      public boolean isForgotten()
    • saveState

      public boolean saveState(OutputObjectState os)
    • restoreState

      public boolean restoreState(InputObjectState os)
    • type

      public String type()
    • typeName

      public static String typeName()
    • setRecoveryCoordinator

      public final void setRecoveryCoordinator(RecoveryCoordinator recCoord)
    • getRecoveryCoordinator

      public final RecoveryCoordinator getRecoveryCoordinator()
      Deprecated.
      Only used in tests
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • setXAResource

      protected void setXAResource(XAResource res)
      For those objects where the original XAResource could not be saved.
    • recover

      protected int recover()
    • updateState

      protected final boolean updateState(int h)