public class CompositeTransactionManagerImp extends Object implements CompositeTransactionManager, SubTxAwareParticipant
| Constructor and Description |
|---|
CompositeTransactionManagerImp() |
| Modifier and Type | Method and Description |
|---|---|
void |
committed(CompositeTransaction tx)
Called if a tx is ended successfully.
|
CompositeTransaction |
createCompositeTransaction(long timeout) |
CompositeTransaction |
getCompositeTransaction() |
CompositeTransaction |
getCompositeTransaction(String tid) |
Participant |
getParticipant(String root)
Get the participant for the given root.
|
CompositeTransaction |
recreateCompositeTransaction(Propagation context,
boolean orphancheck,
boolean heur_commit)
Recreate a composite transaction based on an imported context.
|
void |
resume(CompositeTransaction ct) |
void |
rolledback(CompositeTransaction tx)
Called if a tx is ended with failure.
|
void |
shutdown(boolean force)
Shut down the server in a clean way.
|
protected void |
startlistening(CompositeTransaction transaction) |
CompositeTransaction |
suspend() |
public Participant getParticipant(String root)
root - public void committed(CompositeTransaction tx)
committed in interface SubTxAwareParticipantSubTxAwareParticipantpublic void rolledback(CompositeTransaction tx)
rolledback in interface SubTxAwareParticipantSubTxAwareParticipantpublic CompositeTransaction getCompositeTransaction() throws SysException
getCompositeTransaction in interface CompositeTransactionManagerSysExceptionCompositeTransactionManagerpublic CompositeTransaction getCompositeTransaction(String tid) throws SysException
getCompositeTransaction in interface CompositeTransactionManagerSysExceptionCompositeTransactionManagerpublic CompositeTransaction recreateCompositeTransaction(Propagation context, boolean orphancheck, boolean heur_commit) throws SysException
recreateCompositeTransaction in interface CompositeTransactionManagercontext - The propagationcontext.orphancheck - If true, real composite txs are done. If false, OTS like
behavior applies.heur_commit - True for heuristic commit, false for heuristic rollback.SysException - Failure.public CompositeTransaction suspend() throws SysException
suspend in interface CompositeTransactionManagerSysExceptionCompositeTransactionManagerpublic void resume(CompositeTransaction ct) throws IllegalStateException, SysException
resume in interface CompositeTransactionManagerIllegalStateExceptionSysExceptionCompositeTransactionManagerpublic void shutdown(boolean force)
throws SysException,
IllegalStateException
force - If true, shutdown will not wait for possibly indoubt txs to
finish. Calling shutdown with force being true implies that
shutdown will not fail, but there may be remaining timer
threads that stay asleep until there timeouts expire. Such
remaining active transactions will NOT be able to finish,
because the recovery manager will be shutdown by that time.
New transactions will not be allowed.SysException - For unexpected errors.IllegalStateException - If active txs exist, and not force.protected void startlistening(CompositeTransaction transaction) throws SysException
SysExceptionpublic CompositeTransaction createCompositeTransaction(long timeout) throws SysException
createCompositeTransaction in interface CompositeTransactionManagerSysExceptionCompositeTransactionManagerCopyright © 2016. All Rights Reserved.