Class Transaction

  • All Implemented Interfaces:
    com.arjuna.ats.arjuna.coordinator.Reapable
    Direct Known Subclasses:
    RecoveringTransaction

    public class Transaction
    extends com.arjuna.ats.arjuna.AtomicAction
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected static org.jboss.logging.Logger log  
      • Fields inherited from class com.arjuna.ats.arjuna.AtomicAction

        _timeout, NO_TIMEOUT
      • Fields inherited from class com.arjuna.ats.arjuna.coordinator.BasicAction

        failedList, heuristicList, pendingList, preparedList, readonlyList, savedIntentionList, subordinate, threadStackTraceHistoryList
      • Fields inherited from class com.arjuna.ats.arjuna.StateManager

        modifyingActions, objectModel, objectUid, usingActions
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addVolatileParticipant​(String vparticipantURI)  
      protected boolean afterCompletion​(int arjunaStatus)  
      protected boolean afterCompletion​(int arjunaStatus, boolean report_heuristics)  
      protected boolean beforeCompletion()  
      String enlistParticipant​(String coordinatorUrl, String participantUrl, String recoveryUrlBase, String terminateUrl)  
      String enlistParticipant​(String coordinatorUrl, String participantUrl, String recoveryUrlBase, String commitURI, String prepareURI, String rollbackURI, String commitOnePhaseURI)  
      boolean forgetParticipant​(String participantUrl)  
      String getAge()  
      String getInitiator()  
      void getParticipants​(Collection<String> enlistmentIds)  
      String getRecoveryUrl()  
      String getStatus()  
      String getStatus​(int status)  
      boolean getStatus​(org.jboss.jbossts.star.util.media.txstatusext.TwoPhaseAwareParticipantElement participantElement, String participantUrl)  
      org.jboss.jbossts.star.util.TxStatus getTxStatus()  
      boolean isAlive()  
      boolean isEnlisted​(String participantUrl)
      Determine whether a participant is enlisted in this transaction and the commitment is not running.
      boolean isFinishing()  
      boolean isRunning()  
      protected int lookupStatus()  
      void setFault​(String fault)  
      org.jboss.jbossts.star.util.media.txstatusext.CoordinatorElement toXML()  
      • Methods inherited from class com.arjuna.ats.arjuna.AtomicAction

        abort, addThread, addThread, begin, begin, cancel, checkForCurrent, commit, commit, end, getTimeout, removeThread, removeThread, resume, suspend, type
      • Methods inherited from class com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator

        addSynchronization, asyncAfterCompletion, getDeferredThrowable, getSynchronizations, outputCapturedStackTraces, recordStackTraces, running, start, start
      • Methods inherited from class com.arjuna.ats.arjuna.coordinator.BasicAction

        Abort, Abort, abortStatus, activate, activate, activeThreads, add, addChildAction, addChildThread, addChildThread, addRecord, async_prepare, Begin, childTransactions, commitStatus, createStackTraces, criticalEnd, criticalStart, Current, deactivate, destroy, doAbort, doAbort, doCommit, doCommit, doPrepare, End, equals, finalizeInternal, forgetHeuristics, getDeferredThrowables, getHeuristicDecision, getHierarchy, getSavingUid, getStore, hashCode, hierarchyDepth, insertRecord, isAncestor, maintainHeuristics, onePhaseCommit, onePhaseCommit, parent, phase2Abort, phase2Cleanup, phase2Commit, prepare, preparedStatus, preventCommit, removeChildAction, removeChildThread, removeChildThread, restore_state, save_state, setCheckedAction, setHeuristicDecision, status, topLevelAction, topLevelActionUid, toString, typeOfAction, updateHeuristic, updateState
      • Methods inherited from class com.arjuna.ats.arjuna.StateManager

        cleanup, createLists, deactivate, deactivate, disable, forgetAction, get_uid, getMutex, getObjectModel, getStoreRoot, loadObjectState, lockMutex, modified, objectType, packHeader, persist, print, rememberAction, setStatus, setupStore, setupStore, setupStore, terminate, tryLockMutex, unlockMutex, unpackHeader
      • Methods inherited from interface com.arjuna.ats.arjuna.coordinator.Reapable

        get_uid, preventCommit
    • Field Detail

      • log

        protected static final org.jboss.logging.Logger log
    • Constructor Detail

      • Transaction

        public Transaction()
      • Transaction

        public Transaction​(com.arjuna.ats.arjuna.common.Uid uid)
    • Method Detail

      • toXML

        public org.jboss.jbossts.star.util.media.txstatusext.CoordinatorElement toXML()
      • getInitiator

        public String getInitiator()
      • getAge

        public String getAge()
      • getStatus

        public String getStatus()
      • lookupStatus

        protected int lookupStatus()
      • getStatus

        public String getStatus​(int status)
      • getTxStatus

        public org.jboss.jbossts.star.util.TxStatus getTxStatus()
      • getRecoveryUrl

        public String getRecoveryUrl()
      • enlistParticipant

        public String enlistParticipant​(String coordinatorUrl,
                                        String participantUrl,
                                        String recoveryUrlBase,
                                        String terminateUrl)
      • isEnlisted

        public boolean isEnlisted​(String participantUrl)
        Determine whether a participant is enlisted in this transaction and the commitment is not running.
        Parameters:
        participantUrl - the participant url to search for
        Returns:
        false if the participant is not enlisted or if the commitment protocol is already running
      • forgetParticipant

        public boolean forgetParticipant​(String participantUrl)
      • getParticipants

        public void getParticipants​(Collection<String> enlistmentIds)
      • setFault

        public void setFault​(String fault)
      • isFinishing

        public boolean isFinishing()
      • isAlive

        public boolean isAlive()
      • isRunning

        public boolean isRunning()
      • getStatus

        public boolean getStatus​(org.jboss.jbossts.star.util.media.txstatusext.TwoPhaseAwareParticipantElement participantElement,
                                 String participantUrl)
      • addVolatileParticipant

        public void addVolatileParticipant​(String vparticipantURI)
      • beforeCompletion

        protected boolean beforeCompletion()
        Overrides:
        beforeCompletion in class com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator
      • afterCompletion

        protected boolean afterCompletion​(int arjunaStatus)
        Overrides:
        afterCompletion in class com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator
      • afterCompletion

        protected boolean afterCompletion​(int arjunaStatus,
                                          boolean report_heuristics)
        Overrides:
        afterCompletion in class com.arjuna.ats.arjuna.coordinator.TwoPhaseCoordinator