Function k_disjoint_boundaries_never_conflict
pub async fn k_disjoint_boundaries_never_conflict<F>(
open: impl AsyncFn() -> F,
) -> RuleOutcomeExpand description
Contenders on different consistency boundaries do not conflict.
BOUNDARIES disjoint queries, PER_BOUNDARY contenders each, all
racing at once: against a store that refuses nobody, every boundary
elects exactly one winner, so exactly BOUNDARIES batches land. A
Busy refusal loosens that to at most one; see the last section.
§Why this is the shape of the runbook’s “K seats” and not its letter
The work item asks for K seats and exactly K commits — a capacity
boundary, N contenders competing for K places. That formulation needs a
retry loop: a contender that loses re-reads and tries again until the
seats are full, and the loop needs a budget or it is a livelock waiting
to happen. A budget is an operation count, and asserting a rule fails
when the budget is exhausted is asserting on an operation count, which
CF-33 [FROZEN] forbids for the same anti-flake reason it forbids
clocks.
K disjoint boundaries buy the same arithmetic — exactly K commits out
of N attempts — with one attempt each and no loop, and they reject a
defect the capacity form cannot see at all: an adapter whose concurrency
control is coarser than its condition. A Postgres store under
SERIALIZABLE that maps 40001 serialization_failure onto
AppendError::ConditionViolated is conformant on every sequential rule —
a sequential writer never serialisation-fails — and reports contention
between two commands that share nothing. SpuriousConflictStore in the
proof artefact is that adapter.
The false-negative direction is checked in the same breath: a store that let two contenders onto one boundary fails the per-boundary count.
§What the name promises
Since ADR-0077 the rule holds at most one winner per boundary and
at least one across all of them, not exactly BOUNDARIES. A contender
refused as AppendError::Busy
is neither a win nor a loss, so a
boundary whose every contender was busy passes with no winner — and a
store that refuses disjoint contenders as Busy, a global lock or an
SSI false positive included, passes the rule. ES-43 admits that, and
live PostgreSQL does it. What the rule rejects is a conflict:
ConditionViolated on a boundary nothing had committed to, which is
SpuriousConflictStore and GlobalVersionStore. Independence is a
promise about conflict, not liveness — Busy wrote nothing and the
typed loop retries it — which the owner decided at phase 17, and the
rule was renamed from k_disjoint_boundaries_admit_exactly_k_commits
to say so.