Set transactional state

The transactional state of a component instance determines whether a transactional component’s database updates are committed or rolled back.

To set transactional state, you must use the InstanceContext object retrieved by calling Jaguar.getInstanceContext() in each method that sets transactional state (do not save the object across method invocations, because it will not be valid if the component instance has been deactivated and reactivated). See the EAServer API Reference Manual for information on this method.

To set transaction state, choose the method that reflects the state of the work that the component is contributing to the transaction, as follows:

NoteTransaction control with the ServerBean control interface If you use the deprecated control interface JaguarEJB::ServerBean and Auto demarcation/deactivation option is disabled in the Transactions tab in the Transactions properties for your component, the transaction state specified in the method determines whether the instance is deactivated or remains bound to the client.