Overview
| Artifact ID: | 635a0488b19f13ab177dbee25d0d7f7d603fb1075812b11f40153871b836ce87 |
|---|---|
| Ticket: | 0c51d50626446d4f6139a09ed55485fd30cf0a8b
A failed fold must never advance the cursor: silent, permanent index loss |
| User & Date: | dmestas on 2026-08-19 10:43:52 |
Changes
- Untracked field cmimetype: "text/x-markdown"
- comment changed to:
A fold that fails leaves its artifacts unacked, the publisher cursor advances on a later healthy round, and the messages age out of the bounded stream (1 GiB, one hour, discard-old). The artifacts are then never republished. Nothing errors at the moment of loss. Every surface built on the index renders the hole as if it were the truth, and the only repair is a full store re-read, which needs exclusive access to the index files — so recovering costs an outage. Observed twice now: - as "2 branches on the timeline" when a check-in went missing; - again on 2026-08-19, when a schema change made every ticket fold fail with "no such column". Folds errored for minutes, the cursor advanced, and `ticket_change` went to 0 rows on a store that holds thousands. The failure was loud in the log and completely invisible in the data. ### Required **A failed fold must not advance the cursor.** Retry with backoff; if an artifact keeps failing, stop the pipeline for that repository and alarm. A stalled indexer that says so is strictly better than a silently incomplete one that looks healthy — the store is always correct, so stopping loses nothing but time. ### Also needed - A post-fold completeness invariant: artifacts the store holds versus artifacts the index accounts for, checked per round, alarming on divergence. `lostArtifacts` already does this for dangling parents; generalise it rather than adding a second mechanism. - The check belongs in the serving path, not only in the harness. The disposability test proves a rebuild is faithful; nothing currently proves the RUNNING index is. Related: #d725bd29c5 (tk: artifacts the store holds are missing and a rebuild does not repair it) is very likely the same root cause.
- priority changed to: "Immediate"
- severity changed to: "Critical"
- status changed to: "Open"
- subsystem changed to: "ingest"
- title changed to:
A failed fold must never advance the cursor: silent, permanent index loss
- type changed to: "Code_Defect"