public interface ImportedTransaction extends Transaction
Modifier and Type | Method and Description |
---|---|
boolean |
activated() |
Xid |
baseXid() |
boolean |
doBeforeCompletion()
Run beforeCompletion on Synchronizations.
|
boolean |
doCommit()
Drive the subordinate transaction to commit.
|
void |
doForget()
Called to tell the transaction to forget any heuristics.
|
void |
doOnePhaseCommit()
Drive the transaction to commit.
|
int |
doPrepare()
Drive the subordinate transaction through the prepare phase.
|
void |
doRollback()
Drive the subordinate transaction to roll back.
|
List<Throwable> |
getDeferredThrowables()
Listing deferred throwables gathered during the transaction processing.
|
Object |
getId()
get a unique identifier for this transaction
|
void |
recover() |
boolean |
supportsDeferredThrowables()
Informs if deferred throwables are supported by implementation.
|
commit, delistResource, enlistResource, getStatus, registerSynchronization, rollback, setRollbackOnly
int doPrepare()
boolean doCommit() throws IllegalStateException, HeuristicMixedException, HeuristicRollbackException, HeuristicCommitException, SystemException
IllegalStateException
- thrown if the transaction has not been prepared
or is unknown.HeuristicMixedException
- thrown if a heuristic mixed outcome occurs
(where some participants committed whilst others rolled back).HeuristicRollbackException
- thrown if the transaction rolled back.SystemException
- thrown if some other error occurs.HeuristicCommitException
void doRollback() throws IllegalStateException, HeuristicMixedException, HeuristicCommitException, HeuristicRollbackException, SystemException
IllegalStateException
- thrown if the transaction is not known by the
system or has been previously terminated.HeuristicMixedException
- thrown if a heuristic mixed outcome occurs
(can only happen if the transaction was previously prepared and then only if
some participants commit whilst others roll back).HeuristicCommitException
- thrown if the transaction commits (can only
happen if it was previously prepared).SystemException
- thrown if any other error occurs.HeuristicRollbackException
void doOnePhaseCommit() throws IllegalStateException, HeuristicMixedException, SystemException, RollbackException
IllegalStateException
- if the transaction has already terminatedHeuristicRollbackException
- thrown if the transaction
rolls back.HeuristicMixedException
SystemException
RollbackException
void doForget() throws IllegalStateException
IllegalStateException
- thrown if the transaction cannot
be found.boolean doBeforeCompletion() throws SystemException
SystemException
boolean activated()
void recover()
Xid baseXid()
Object getId()
List<Throwable> getDeferredThrowables()
Listing deferred throwables gathered during the transaction processing. This list contains exceptions thrown by transaction resources when an error occurs.
Depending on the transaction stage the particular method returns only an error code e.g. doPrepare()
then the controller of the subordinate transaction throws its own exception and it could
pack these throwables in some details.
Other methods as doCommit()
throws an exception but those exception does not contain
underlying exceptions like those coming from resource failures.
Normally exceptions taken by this call are put under suppressed part of the thrown exception.
JTS implementation of the SubordinateTransaction
interface does not support the deferred throwable
based on the limitation of ORB protocol. This method called on JTS implementation causes UnsupportedOperationException
being thrown.
UnsupportedOperationException
- for JTS implementationboolean supportsDeferredThrowables()
Informs if deferred throwables are supported by implementation. See getDeferredThrowables()
.
Copyright © 2023 JBoss by Red Hat. All rights reserved.