org.omg.CosTransactions
Interface SynchronizationOperations

All Superinterfaces:
TransactionalObjectOperations
All Known Subinterfaces:
Synchronization
All Known Implementing Classes:
_SynchronizationStub, SynchronizationPOA

public interface SynchronizationOperations
extends TransactionalObjectOperations

The Transaction Service provides a synchronization protocol which enables an object with transient state data that relies on an X/Open XA conformant Resource Manager for ensuring that data is made persistent, to be notified before the start of the two-phase commitment protocol, and after its completion. An object with transient state data that relies on a Resource object for ensuring that data is made persistent can also make use of this protocol, provided that both objects are registered with the same Coordinator. Each object supporting the Synchronization interface is implicitly associated with a single top-level transaction.


Method Summary
 void after_completion(Status status)
          This operation is invoked after all commit or rollback responses have been received by this coordinator.
 void before_completion()
          This operation is invoked prior to the start of the two-phase commit protocol within the coordinator the Synchronization has registered with.
 

Method Detail

before_completion

public void before_completion()
This operation is invoked prior to the start of the two-phase commit protocol within the coordinator the Synchronization has registered with. This operation will therefore be invoked prior to prepare being issued to Resource objects or X/Open Resource Managers registered with that same coordinator. The Synchronization object must ensure that any state data it has that needs to be made persistent is made available to the resource. Only standard exceptions may be raised. Unless there is a defined recovery procedure for the exception raised, the transaction should be marked rollback only.


after_completion

public void after_completion(Status status)
This operation is invoked after all commit or rollback responses have been received by this coordinator. The current status of the transaction (as determined by a get_status on the Coordinator) is provided as input. Only standard exceptions may be raised and they have no effect on the outcome of the commitment process.