Health & Crash Recovery

Inspect sync thread health and recover telemetry buffered to pending.jsonl after crashes.

Agent hint

Use for get_health / getHealth, events_dropped, patch_status, and pending file recovery.

In scope

  • Health dict fields
  • Crash durability via pending.jsonl
  • patch_status visibility

Out of scope

  • Cloud sync retry config — see Cloud Sync Resilience
  • Serverless flush — see Serverless Flush

On unclean shutdown, events spill to pending.jsonl and replay on next startup.

Python
health = auditor.get_health()
# status, queue_size, events_dropped, sync_error_count,
# patch_status, storage_mode, ledger_path, pending_file_exists
Node.js
const health = auditor.getHealth();
// status, queueSize, eventsDropped, syncErrorCount,
// patchStatus, storageMode, ledgerPath

See also