Skip to main content

Module reconcile

Module reconcile 

Source
Expand description

The reconciler: what the producers were told against what the readers saw.

The question it answers is narrower than “did every record arrive”. A producer that was told a send failed may have written it anyway, and an application that resends after a failure may legitimately write a record twice. Neither is data loss, and a reconciler that called them failures would teach its readers to ignore it. So every observation is classified against the semantics the path declared:

observationidempotenttransactionalcompacted
acknowledged, not readlostlost if its transaction committed (read_committed) or at all (read_uncommitted)–
read twice, sent onceunexpected duplicateunexpected duplicate–
read twice, sent again after a failurepermitted––
read, send failedpermitted (maybe delivered)permittedpermitted
read, never sentphantomphantomphantom
aborted, read under read_committed–aborted visible–
outcome unknown, partly read under read_committed–partial transaction–
key’s latest acknowledged value not read––compaction regression

Committed offsets are checked separately: after each fault, the offset a group fetches back must be no lower than the last commit the coordinator acknowledged before it, and no higher than the log end.

Structs§

Finding
One failure of the reconciliation.
Reconciliation
The reconciler’s whole answer.
Tally
What reconciliation counted for one producer and reader, pass or fail.

Enums§

FindingKind
A class of reconciliation failure.

Functions§

reconcile
Reconcile evidence against the semantics contract declares.