|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface CompositeTransaction
Represents a nested part of a global composite transaction. Each invocation of a server is represented by an instance of this type. For transaction proxies (instances that represent non-local transactions), all non-trivial methods are allowed to generate an exception of type UnsupportedOperationException. The only methods that always work for all instances are the simple getters and test methods.
| Method Summary | |
|---|---|
RecoveryCoordinator |
addParticipant(Participant participant)
|
void |
addSubTxAwareParticipant(SubTxAwareParticipant subtxaware)
Resources that support lock inheritance can use this feature to be notified whenever a lock should be inherited. |
void |
commit()
Commits the composite transaction. |
CompositeTransaction |
createSubTransaction()
|
CompositeCoordinator |
getCompositeCoordinator()
|
Extent |
getExtent()
|
java.util.Stack<CompositeTransaction> |
getLineage()
|
int |
getLocalSubTxCount()
|
java.util.Properties |
getProperties()
Gets all properties of this instance. |
java.lang.String |
getProperty(java.lang.String name)
Gets the specified metadata property. |
TxState |
getState()
Gets the current state. |
java.lang.String |
getTid()
|
long |
getTimeout()
|
boolean |
isAncestorOf(CompositeTransaction otherCompositeTransaction)
|
boolean |
isDescendantOf(CompositeTransaction otherCompositeTransaction)
|
boolean |
isLocal()
|
boolean |
isRelatedTransaction(CompositeTransaction otherCompositeTransaction)
|
boolean |
isRoot()
|
boolean |
isSameTransaction(CompositeTransaction otherCompositeTransaction)
|
boolean |
isSerial()
Serial mode is an optimized way for lock inheritance: no locks among related transactions are necessary if all related transactions are executed serially with respect to each other. |
void |
registerSynchronization(Synchronization sync)
|
void |
rollback()
Rollback of the current transaction. |
void |
setProperty(java.lang.String name,
java.lang.String value)
Sets metadata property information on the transaction object. |
void |
setRollbackOnly()
Marks the transaction so that the only possible termination is rollback. |
void |
setSerial()
Set serial mode for root. |
| Method Detail |
|---|
TxState getState()
TxStateboolean isRoot()
java.util.Stack<CompositeTransaction> getLineage()
java.lang.String getTid()
boolean isAncestorOf(CompositeTransaction otherCompositeTransaction)
otherCompositeTransaction -
boolean isDescendantOf(CompositeTransaction otherCompositeTransaction)
otherCompositeTransaction -
boolean isRelatedTransaction(CompositeTransaction otherCompositeTransaction)
otherCompositeTransaction -
boolean isSameTransaction(CompositeTransaction otherCompositeTransaction)
otherCompositeTransaction -
CompositeCoordinator getCompositeCoordinator()
throws SysException
SysException
RecoveryCoordinator addParticipant(Participant participant)
throws SysException,
java.lang.IllegalStateException
participant -
SysException
java.lang.IllegalStateException
void registerSynchronization(Synchronization sync)
throws java.lang.IllegalStateException,
SysException
sync -
java.lang.IllegalStateException
SysException
void addSubTxAwareParticipant(SubTxAwareParticipant subtxaware)
throws SysException,
java.lang.IllegalStateException
subtxaware -
SysException
java.lang.IllegalStateExceptionboolean isSerial()
boolean isLocal()
Extent getExtent()
long getTimeout()
void setRollbackOnly()
void commit()
throws HeurRollbackException,
HeurMixedException,
HeurHazardException,
SysException,
java.lang.SecurityException,
RollbackException
HeurRollbackException - On heuristic rollback.
HeurMixedException - On heuristic mixed outcome.
SysException - For unexpected failures.
java.lang.SecurityException - If calling thread does not have
right to commit.
HeurHazardException - In case of heuristic hazard.
RollbackException - If the transaction was rolled back
before prepare.
void rollback()
throws java.lang.IllegalStateException,
SysException
java.lang.IllegalStateException - If prepared or inactive.
SysException - If unexpected error.
void setProperty(java.lang.String name,
java.lang.String value)
name - value - java.lang.String getProperty(java.lang.String name)
name - The name of the property.
java.util.Properties getProperties()
CompositeTransaction createSubTransaction()
void setSerial()
throws java.lang.IllegalStateException,
SysException
java.lang.IllegalStateException - If called for non-root tx.
SysException - For unexpected errors.int getLocalSubTxCount()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||