It imposes less overhead
Also based on Timestamp Protocol. It has three phases:
- Read Phase: During this phase, the system executes transaction Ti. . It reads the values of the various data items and stores them in variable local to Ti. It performs all the write operations on temporary local variables without update of the actual database.
- Validation Phase: Transaction Ti performs a validation test to determine whether it can copy to database the temporary local variables that hold the result of write operations without causing a violation of serializability.
- Write Phase: If Transaction Ti succeeds in validation, then the system applies the actual updates to the database, otherwise the system rolls back Ti.
To perform the validation test, we need to know when the various phases of transaction Titook place. We shall therefore associate three different timestamps with transaction Ti.
1. Start (Ti): the time when Ti, started its execution.
2. Validation (Ti): the time when Ti finished its read phase and started its validation phase.
3. Finish (Ti): the time when Ti finished its write phase.
The Validation Test for Tj requires that, for all transaction Ti with TS(Ti ) < TS(Tj ) one of the following condition must hold
- Finish (Ti) < Start (Tj): Since Ti completes its execution before Tj started, the serializability order is indeed maintained.
- Start(Tj )<Finish(Ti ) <validation(Tj ): The validation phase of Tj should occur after Tifinishes.
Few Points
- Resolves the cascade rollbacks
- Suffers from the starvation.
- Optimistic concurrency control.