Interface RollbackHandler<T extends ProcessContext<?>>
- All Known Implementing Classes:
CommitTaxRollbackHandler,CompleteOrderRollbackHandler,ConfirmPaymentsRollbackHandler,DecrementInventoryRollbackHandler,NullCheckoutRollbackHandler,RecordOfferUsageRollbackHandler
public interface RollbackHandler<T extends ProcessContext<?>>
Implementations are responsible for performing compensating operations to revert the state of the activity to what it
was prior to execution. Activity, ProcessContext and stateConfiguration variables can be used to gather the necessary
information to successfully perform the compensating operation.
- Author:
- Jeff Fischer
-
Method Summary
-
Method Details
-
rollbackState
void rollbackState(Activity<T> activity, T processContext, Map<String, Object> stateConfiguration) throws RollbackFailureExceptionRollback the state of the activity to what it was prior to execution.- Parameters:
activity- The Activity instance whose state is being revertedprocessContext- The ProcessContext for the workflowstateConfiguration- Any user-defined state configuration associated with the RollbackHandler- Throws:
RollbackFailureException- if there is a failure during the execution of the rollback
-