public class ArjunaTransactionImple extends TwoPhaseCoordinator implements ArjunaTransactionOperations
Modifier and Type | Field and Description |
---|---|
protected ControlImple |
controlHandle |
protected ArjunaTransactionImple |
parentTransaction |
failedList, heuristicList, pendingList, preparedList, readonlyList, savedIntentionList
modifyingActions, objectModel, objectUid, usingActions
Modifier | Constructor and Description |
---|---|
|
ArjunaTransactionImple(Control myParent) |
|
ArjunaTransactionImple(Control myParent,
ArjunaTransactionImple parent) |
protected |
ArjunaTransactionImple(Uid actUid)
For crash recovery purposes only.
|
|
ArjunaTransactionImple(Uid actUid,
Control myParent) |
|
ArjunaTransactionImple(Uid actUid,
Control myParent,
ArjunaTransactionImple parent) |
Modifier and Type | Method and Description |
---|---|
void |
commit(boolean report_heuristics)
If the transaction has already been committed (by another thread, for
example) then we do nothing - could throw TransactionRequired or
INVALID_TRANSACTION.
|
Control |
create_subtransaction() |
protected AbstractRecord |
createOTSRecord(boolean propagate,
Resource resource,
Coordinator coord) |
protected AbstractRecord |
createOTSRecord(boolean propagate,
Resource resource,
Coordinator coord,
Uid recCoordUid) |
protected void |
destroyAction() |
protected void |
doAfterCompletion(Status myStatus) |
protected void |
doBeforeCompletion() |
boolean |
equals(Object o) |
void |
finalize() |
boolean |
forgetHeuristics()
Forget any heuristics we may have received, and tell the resources which
generated them to forget too.
|
Status |
get_parent_status() |
Status |
get_status() |
Status |
get_top_level_status() |
String |
get_transaction_name()
To be used for debugging purposes only.
|
PropagationContext |
get_txcontext() |
ControlImple |
getControlHandle() |
Map<Uid,String> |
getSynchronizations() |
int |
hash_top_level_tran() |
int |
hash_transaction() |
static int |
interpositionType() |
boolean |
is_ancestor_transaction(Coordinator tc)
Is this transaction an ancestor of tc?
|
boolean |
is_descendant_transaction(Coordinator tc)
Is this transaction a descendant of tc?
|
boolean |
is_related_transaction(Coordinator tc) |
boolean |
is_same_transaction(Coordinator tc) |
boolean |
is_top_level_transaction() |
RecoveryCoordinator |
register_resource(Resource r)
Resources are only registered with the current transaction, whereas
subtransaction aware resources are registered with their parents when the
current transaction ends.
|
void |
register_subtran_aware(SubtransactionAwareResource r)
Do not propagate the resource to the parent.
|
void |
register_synchronization(Synchronization sync)
The spec states that a synchronization is registered with a single
top-level action only.
|
void |
rollback_only() |
void |
rollback() |
void |
setControlHandle(ControlImple handle) |
String |
topLevelUid() |
String |
toString()
Overloads Object.toString()
|
String |
type()
Overloads BasicAction.type()
|
static String |
typeName() |
String |
uid()
We use these to determine relationships between transactions.
|
addSynchronization, afterCompletion, afterCompletion, asyncAfterCompletion, beforeCompletion, cancel, end, getDeferredThrowable, running, start, start
Abort, Abort, abortStatus, activate, activate, activeThreads, add, addChildAction, addChildThread, addChildThread, addRecord, async_prepare, Begin, checkForCurrent, childTransactions, commitStatus, criticalEnd, criticalStart, Current, deactivate, destroy, doAbort, doAbort, doCommit, doCommit, doPrepare, End, finalizeInternal, getDeferredThrowables, getHeuristicDecision, getHierarchy, getSavingUid, getStore, hashCode, hierarchyDepth, insertRecord, isAncestor, maintainHeuristics, onePhaseCommit, parent, phase2Abort, phase2Cleanup, phase2Commit, prepare, preparedStatus, preventCommit, removeChildAction, removeChildThread, removeChildThread, restore_state, save_state, setCheckedAction, setHeuristicDecision, status, topLevelAction, topLevelActionUid, typeOfAction, updateHeuristic, updateState
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
get_uid, preventCommit
protected ArjunaTransactionImple parentTransaction
protected ControlImple controlHandle
public ArjunaTransactionImple(Control myParent)
public ArjunaTransactionImple(Control myParent, ArjunaTransactionImple parent)
public ArjunaTransactionImple(Uid actUid, Control myParent, ArjunaTransactionImple parent)
protected ArjunaTransactionImple(Uid actUid)
public final ControlImple getControlHandle()
public final void setControlHandle(ControlImple handle)
public void commit(boolean report_heuristics) throws HeuristicMixed, HeuristicHazard, SystemException
commit
in interface TerminatorOperations
HeuristicMixed
HeuristicHazard
SystemException
public void rollback() throws SystemException
rollback
in interface TerminatorOperations
SystemException
public Status get_status() throws SystemException
get_status
in interface CoordinatorOperations
SystemException
public Status get_parent_status() throws SystemException
get_parent_status
in interface CoordinatorOperations
SystemException
public Status get_top_level_status() throws SystemException
get_top_level_status
in interface CoordinatorOperations
SystemException
public boolean is_same_transaction(Coordinator tc) throws SystemException
is_same_transaction
in interface CoordinatorOperations
SystemException
public boolean is_related_transaction(Coordinator tc) throws SystemException
is_related_transaction
in interface CoordinatorOperations
SystemException
public boolean is_ancestor_transaction(Coordinator tc) throws SystemException
is_ancestor_transaction
in interface CoordinatorOperations
SystemException
public boolean is_descendant_transaction(Coordinator tc) throws SystemException
is_descendant_transaction
in interface CoordinatorOperations
SystemException
public boolean is_top_level_transaction() throws SystemException
is_top_level_transaction
in interface CoordinatorOperations
SystemException
public int hash_transaction() throws SystemException
hash_transaction
in interface CoordinatorOperations
SystemException
public int hash_top_level_tran() throws SystemException
hash_top_level_tran
in interface CoordinatorOperations
SystemException
public RecoveryCoordinator register_resource(Resource r) throws SystemException, Inactive
register_resource
in interface CoordinatorOperations
SystemException
Inactive
public void register_subtran_aware(SubtransactionAwareResource r) throws Inactive, NotSubtransaction, SystemException
register_subtran_aware
in interface CoordinatorOperations
Inactive
NotSubtransaction
SystemException
public void rollback_only() throws SystemException, Inactive
rollback_only
in interface CoordinatorOperations
SystemException
Inactive
public String get_transaction_name() throws SystemException
get_transaction_name
in interface CoordinatorOperations
SystemException
public Control create_subtransaction() throws SystemException, SubtransactionsUnavailable, Inactive
create_subtransaction
in interface CoordinatorOperations
SystemException
SubtransactionsUnavailable
Inactive
public void register_synchronization(Synchronization sync) throws Inactive, SynchronizationUnavailable, SystemException
register_synchronization
in interface CoordinatorOperations
Inactive
SynchronizationUnavailable
SystemException
public PropagationContext get_txcontext() throws Unavailable, SystemException
get_txcontext
in interface CoordinatorOperations
Unavailable
SystemException
public String uid() throws SystemException
uid
in interface UidCoordinatorOperations
SystemException
public String topLevelUid() throws SystemException
topLevelUid
in interface UidCoordinatorOperations
SystemException
public String type()
TwoPhaseCoordinator
type
in class TwoPhaseCoordinator
public static final int interpositionType()
public static String typeName()
public String toString()
BasicAction
toString
in class BasicAction
public boolean equals(Object o)
equals
in class BasicAction
public boolean forgetHeuristics()
BasicAction
forgetHeuristics
in class BasicAction
true
if heuristic information (if any) was
successfully forgotten, false
otherwise.protected void doBeforeCompletion() throws SystemException
SystemException
protected void doAfterCompletion(Status myStatus) throws SystemException
SystemException
protected final AbstractRecord createOTSRecord(boolean propagate, Resource resource, Coordinator coord)
protected final AbstractRecord createOTSRecord(boolean propagate, Resource resource, Coordinator coord, Uid recCoordUid)
protected final void destroyAction()
public Map<Uid,String> getSynchronizations()
getSynchronizations
in class TwoPhaseCoordinator
Copyright © 2021 JBoss by Red Hat. All rights reserved.