153
backfill
Recompute history after the rule changes. Do it in slices. Do not lock the live table to rewrite the past.
What is backfill?
A backfill applies a new transformation or column to existing data. It is a batch job with a watermark, chunked so production traffic still fits. It is idempotent so a retry does not double-apply.
Why does backfill matter when vibe coding?
Models `UPDATE` the whole table in one transaction. The table locks. Name chunks, a resume point, and a way to tell old rows from new.
How do you do backfill?
Chunk by key range. Record progress. New writes use the new rule immediately. The backfill only repairs old rows. Throttle it.
How do you ask a model for backfill?
Backfill (column or table) in key-range chunks. Save progress. Keep it idempotent. Throttle so live traffic still fits. Do not update the entire table in one transaction.
What goes wrong with backfill?
A backfill that pages by OFFSET while new rows arrive. You skip and you repeat. Walk a key.