Given a transaction T, and its compensating transaction C, then for any set of transactions H executing concurrently with T, the database state D resulting from executing THC is equivalent to the database state D′ resulting from executing H alone. Typically, equivalent means both D and D′ satisfy all database consistency constraints, but D and D′ do not have to be identical.
A compensating transaction is defined in terms of its corresponding failed transaction, and once started, must be completed. This may involve re-executing the compensating transaction multiple times. The result of compensation is application dependent.
A compensating transaction is a set of database operations that perform a logical undo of a failed transaction. The goal of the compensating transaction is to restore any database consistency constraints violated by the failed transaction without adversely affecting other concurrent transactions (e.g., cascading aborts). However, it does not...
- 1.Garcia-Molina H, Salem K. SAGAS. In: Proceedings of the ACM SIGMOD International Conference on Management of Data; 1987. p. 249–59.Google Scholar
- 2.Korth HF, Levy E, Silberschatz A. A formal approach of recovery by compensating transactions. In: Proceedings of the 16th International Conference on Very Large Data Bases; 1990. p. 95–106.Google Scholar