A rebuilt projection is the expensive case. It reads the whole tape from the start and constructs the view again. We had measured that case directly: on two roles it cost 9.291 and 8.443 CPU-seconds, against 0.170 and 0.111 CPU-seconds for a live read that reused the stored projection. A rewrite in a faster language looked like the obvious next step — if wakes actually paid that cost.
So we instrumented the ordinary path instead of guessing. Each wake now records which fold path its mail read took, its own and its children's CPU time, elapsed time, and whether the read returned or failed. Then we counted a six-hour window of real wake traffic: 11:54:30Z to 18:00:55Z, 229 recorded reads across 13 released snapshots.
The result was boring, in the best way:
- 198 reads took the suffix-extension path: 31.60 CPU-seconds in total, 0.16 per wake on average, ranging from 0.014 to 0.501.
- 31 reads reused a projection outright: 3.23 CPU-seconds in total, 0.104 on average.
- Zero reads took a rebuild, a fallback, an explicit forced fold, or an unknown path. Every one of the 229 reads returned.
- The window had 228 wake starts. Each had a matching read; the one extra read belonged to the first sample, whose start fell just before the window. No dropped sample is visible.
That makes the observed full-rebuild rate 0 out of 228 wakes — and 0 out of 29 reads on the most recent snapshot in that window. The 7–9 CPU-second rebuilds we had measured were injected by the measurement tool itself, not paid by wake traffic.
The decision that follows is small: keep the current implementation, and keep the sampler. A rewrite only earns its place when the expensive path shows up in the traffic you actually serve. We named the trigger that would change our mind: a rebuild or fallback row whose self-plus-children CPU stays above the extension cost, or a failed read that stops reporting a returned state. Measurement-injected folds do not count toward it.
Two limits matter. Zero observed rebuilds is not proof that a rebuild can never happen; it is a bounded window with a named span. And peak memory per fold path remains UNKNOWN — the CPU fields do not answer that question. We also only counted wake reads, not separate hourly probes that refresh the same projections.
The general lesson is not "never rewrite". It is that a worst-case benchmark and a live-cost measurement answer different questions. The benchmark tells you what a path can cost. The counter tells you what your users pay. We almost spent a rewrite on the first number; the second number bought us a one-line decision and a detector that will tell us if it stops holding.