09 / all the way down

The repair service had opened four hundred thousand tickets against itself.

[ALERT] INC-0009 — Autorepair cascade, unbounded
[INFO ] unwind budget: d-8k
[WARN ] frames open: 412,880 and climbing
[WARN ] resident stack: 2.0 GB
[CRITC] defect queue is being produced faster than it is consumed
[CRITC] producer: autorepair
[CRITC] consumer: autorepair

It had started, as far as anyone could reconstruct, with a genuinely malformed config value at 04:12. resolve had corrected it. expand had looked at the correction, decided it was malformed, and corrected it. inline had looked at that, and so on, around a ring of four stages that were each doing their job perfectly well on an input that was now entirely made of previous repairs.

Andy watched the frame counter climb for a while.

“Why doesn’t it stop?”

“Something stops,” Bob said. “Three of those four stages have a base case and they’re hitting it — you can see it, their depth counters are sitting still.”

He drank some coffee.

“One of them has a base case it can never reach. That one has been going since quarter past four this morning and it’s the only reason the other three are still being handed work.”

evidence retained
  1. No frame re-enters itself directly. Every call in the trace is to a different frame.
  2. resolve bottomed out at d-128.
  3. resolve calls expand.
  4. emit peaked at 32 MB of stack.
  5. The frame that reached d-4k peaked at 256 MB.
  6. Whatever calls inline also peaked at 256 MB.
  7. The frame that calls expand did not reach 2 GB.
  8. inline did not stop at d-512.
  9. Recovered from frame 4096 of the cascade, between two identical stack traces: nx::src=…
messages bob
Bob 09:14

Don't kill it yet. If you kill it now you get 400,000 half-applied repairs and a much worse morning.

Bob 09:16

Columns are frames, call targets, depths. Rows are stack, depths, call targets.

Bob 09:17

Nothing calls itself. That's the same trick as your first week — it tells you more than it looks like it does.

Bob 09:19

Find the frame that never terminates. Format: frame, calls, depth, stack.

table autorepair frames

fault

Unbounded self-repair

unwind budget

d-8k

severity

SEV-1

Skip the grid, go to the answer
resolve expand inline emit →resolve →expand →inline →emit d-128 d-512 d-4k d-∞
4 MB
32 MB
256 MB
2 GB
d-128
d-512
d-4k
d-∞
→resolve
→expand
→inline
→emit
answer input incident response

Question: Which frame never terminates — what does it call, how deep did it go, and how much stack did it take?