Package com.ibm.websphere.jtaextensions
Interface ExtendedJTATransaction
-
public interface ExtendedJTATransactionA WebSphere programming model extension to the J2EE JTA support. An object implementing this interface will be bound, by WebSphere J2EE containers that support this interface, atjava:comp/websphere/ExtendedJTATransaction. Access to this object, when called from an EJB container, is not restricted to BMTs.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description byte[]getGlobalId()Returns theCosTransactions::PropagationContext::TransIdentity::tidfor the transaction currently associated with the calling thread.intgetLocalId()Returns a process-unique identifier for the transaction currently associated with the calling thread.voidregisterSynchronizationCallback(SynchronizationCallback sync)Register a SynchronizationCallbackSynchronizationCallbackobject with the transaction manager.voidregisterSynchronizationCallbackForCurrentTran(SynchronizationCallback sync)Deprecated.This method is deprecated in favor of registerInterposedSynchronization on javax.transaction.TransactionSynchronizationRegistry.voidunRegisterSynchronizationCallback(SynchronizationCallback sync)Unregister a previously registeredSynchronizationCallbackobject,sync.
-
-
-
Method Detail
-
getGlobalId
byte[] getGlobalId()
Returns theCosTransactions::PropagationContext::TransIdentity::tidfor the transaction currently associated with the calling thread.- Returns:
- the current transaction
tidin the form of a byte array. If there is no active transaction currently associated with the thread, returns null;
-
getLocalId
int getLocalId()
Returns a process-unique identifier for the transaction currently associated with the calling thread. The local-id is valid only within the local process. The local-id is recovered as part of the state of a recovered transaction.- Returns:
- an integer that uniquely identifies the current transaction within the calling process. If there is no active transaction currently associated with the thread, returns 0;
-
registerSynchronizationCallback
void registerSynchronizationCallback(SynchronizationCallback sync) throws NotSupportedException
Register a SynchronizationCallbackSynchronizationCallbackobject with the transaction manager. The registeredsyncreceives notification of the completion of each transaction mediated by the transaction manager in the local JVM.- Parameters:
sync- An object implementing theSynchronizationCallbackinterface.- Throws:
NotSupportedException- Thrown if this method is called from an environment or at a time when the function is not available.
-
registerSynchronizationCallbackForCurrentTran
void registerSynchronizationCallbackForCurrentTran(SynchronizationCallback sync) throws NotSupportedException
Deprecated.This method is deprecated in favor of registerInterposedSynchronization on javax.transaction.TransactionSynchronizationRegistry.Register a SynchronizationCallbackSynchronizationCallbackobject for the current transaction. The registeredsyncreceives notification of the completion of the transaction in which it is registered.- Parameters:
sync- An object implementing theSynchronizationCallbackinterface.- Throws:
NotSupportedException- Thrown if this method is called from an environment or at a time when the function is not available.
-
unRegisterSynchronizationCallback
void unRegisterSynchronizationCallback(SynchronizationCallback sync) throws CallbackNotRegisteredException
Unregister a previously registeredSynchronizationCallbackobject,sync. The object so unregistered will receive no further callbacks from transactions that subsequently complete.- Parameters:
sync- A previously registeredSynchronizationCallbackobject.- Throws:
CallbackNotRegisteredException- Thrown if the specificsyncis not registered with the transaction manager.
-
-