CSE Roadmap

Specialist tier · about 3 hours · 5 parts

Part 4 of 5 · 2 min read

Recoverable, cascadeless, and strict schedules

Three increasingly strict conditions on how a schedule handles aborts.

Recoverable, cascadeless, and strict schedules

Think of three increasingly careful policies for sharing a shared document. One: never let anyone save based on someone else's unsaved draft. Two: never even let anyone read someone else's unsaved draft at all. Three: never let anyone touch a value someone else is still mid-edit on, full stop.

In plain words: a schedule is recoverable if, whenever a transaction reads a value written by another transaction, the writer commits before the reader does; this prevents a reader from ending up dependent on a transaction that later aborts. A schedule is cascadeless, a stricter condition, if a transaction never even reads a value written by another transaction until that writer has already committed, preventing a chain of aborts from cascading through several transactions at once. A schedule is strict, the strictest of the three, if a transaction never reads or writes a value already written by another transaction until that other transaction has committed or aborted.

A worked example. A cascadeless schedule never lets transaction B read a row that transaction A wrote until A has actually committed, so if A later aborted instead, B would simply never have read that uncommitted value in the first place.

The key lines. No new SQL; these are properties of a schedule's structure, directly shaping how rollback, covered in Level 8's recovery modules, needs to behave.

Recoverable, cascadeless, strict schedule

A recoverable schedule commits a writer before any reader of its value commits; a cascadeless schedule delays even reading an uncommitted write until the writer commits; a strict schedule delays any read or write of a value until its writer has committed or aborted.

Example: never saving based on an unsaved draft is recoverable; never even reading one is cascadeless; never touching a value someone is still mid-edit on at all is strict.

Remember this

Conflict serializability answers "is this interleaving correct at all," using the precedence graph. Recoverable, cascadeless, and strict answer a separate question: "how safely does this schedule handle a transaction that aborts." The locking protocols covered two pages from now are built to guarantee both.

Quick notes

  • A schedule is the actual order of operations across one or more transactions; a serial schedule never interleaves them.
  • Conflict serializability checks whether an interleaved schedule is equivalent to some serial schedule, via a precedence graph.
  • A precedence graph with no cycle means the schedule is conflict serializable.
  • Recoverable, cascadeless, and strict are increasingly strict conditions on how a schedule handles aborted transactions.
  • These definitions give later pages' isolation levels and locking protocols a precise target to guarantee.