fix(daemon): retry provider lease record retirement

Merged
TH
2h ago
+269-19

Summary

Track an expired lease record write independently once the provider confirms release. Retry it while the daemon owns registration and keep the provider result and drain accounting intact.

Before / after

  • Before: a failed write after provider confirmation could leave a stale record. Retrying an isolated disk failure every second would keep logging with no provider work left.
  • After: a retirement write alone gets one timer retry. Drain, shutdown, and registration handoff can still finish it when the disk recovers. Every close attempts the final write. An in-flight confirmation can still retire the record after a close that keeps registration. A confirmation after handoff leaves the inherited record for the successor.

Validation

At 35e96ce62d, 55 focused tests, lint, typecheck, Fallow, and git diff --check passed locally. The new runtime regression confirmed the record remained on disk at 389f6889da and was removed after the fix. All 21 hosted checks passed on the same head, Sentinel approved it, and both inline threads are resolved.


Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.