Skip to content
We areTOP 1%

What are recoverable, cascadeless and strict schedules?

HardConceptTransactions & ACID
Track your progress
First attempt
Re-solve after a few days
Final pass before interviews

Answer

These properties describe how safely a schedule copes with a transaction that aborts.

  • Recoverable: if Tj reads data written by Ti, then Ti commits before Tj commits. Otherwise Tj may commit a value that later turns out never to have existed.
  • Cascadeless: transactions read only committed data. Without this, one abort can force a chain of other aborts, called a cascading rollback.
  • Strict: no transaction reads or overwrites an item until the transaction that last wrote it has committed or aborted. Strict two-phase locking produces strict schedules.
  • Every strict schedule is cascadeless, and every cascadeless schedule is recoverable.

Example:

T1:  W(A)                    ABORT
T2:         R(A)    COMMIT

T2 reads the value of A written by T1 and commits before T1 finishes. When T1 then aborts, T2 has already committed using a value that never officially existed, so the schedule is not recoverable. If T2 had delayed its commit until after T1, the schedule would be recoverable, but T2 would still have to roll back (a cascading rollback).

More in Transactions & ACID

Sign in to track your progress

Your checkboxes, streak and activity heatmap are saved to your account and sync across devices. It is free.
Sign in with email

New here? Create an account