liveBook · Manning

Liveness

As explained in Think Distributed Systems

A system guarantee that a specified good event or condition will eventually occur.

Liveness is a system guarantee that something good eventually happens. A system is correct only when every possible behavior satisfies both its safety and liveness guarantees. section 1.4.1

Safety prevents an unwanted state; liveness prevents permanent inaction. Together, they require a system to avoid conflicting outcomes and eventually make legitimate progress. section 1.4.1

Two-participant transaction

For a transaction involving participants P1 and P2, safety forbids one participant from committing while the other aborts. Liveness requires both participants eventually to commit or both to abort. section 1.4.1

Liveness appears in several forms:

  • A state machine is live when it eventually reaches each required state; a system with x alternating between 1 and 2 is live, while an unrecoverable x = 3 state has no such guarantee. section 3.2.4
  • Failure mitigation restores liveness after a failure, whereas failure detection commonly protects safety by inhibiting dangerous actions. section 3.3.2
  • Consensus expresses liveness as termination: every nonfailed process eventually decides on a value. section 10.2

Liveness depends on the system model and failure assumptions. Two-phase commit preserves safety but can lose liveness when its transaction coordinator fails; asynchronous systems without clocks cannot guarantee consensus under all circumstances, even with one possible node failure. section 6.3.2 section 10.1

Figure 1.9 Behavior space of a distributed transaction with two participants
A diagram of a work flow

AI-generated content may be incorrect.

Trace the behavior space of a two-participant transaction and see how safety and liveness constrain its possible states. section 1.4.1

How Think Distributed Systems covers it

How deep it goes
Defines eventual good events, formalizes transaction and consensus guarantees, and examines failure and asynchronous-model limits.
Examples
Uses alternating state transitions, two-participant commit-or-abort decisions, coordinator blocking, and consensus termination.
What it assumes
Assumes basic processes, states, messages, and failures while introducing safety, liveness, and formal consensus properties.
What you can do after
Evaluate/understand whether system behaviors eventually reach required states, decisions, or recovery outcomes under stated failures.
How it connects
Connects liveness to safety, failure mitigation, distributed transactions, atomic commit, consensus, and asynchronous distributed systems.

Also explained in

Compare how 2 books explain liveness →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Think Distributed Systems. The section links point to the parts of the book it draws on.