Problem
daemon/heartbeat.c implements frame-count anomaly detection (freeze/rewind) and timeout tracking. It has 10 unit tests, all passing. But it's never called from the daemon's event loop or connected to the Lambda telemetry API (platform/api/handler.py has POST /heartbeat ready).
The heartbeat tracker is dead code in production — fully implemented, tested, and unused.
What exists
daemon/heartbeat.{h,c} — owl_hb_register(), owl_hb_process(), owl_hb_check_timeout(), anomaly detection
platform/api/handler.py — POST /heartbeat endpoint, returns action (continue/kill/pause), DynamoDB storage
daemon/main.c — no heartbeat initialization, no periodic heartbeat send, no telemetry HTTP client
What's missing
- Heartbeat send loop — periodic POST to telemetry API with frame count, state hash, timestamp
- HTTP client in daemon — libcurl is already in LDFLAGS (
-lcurl) but unused
- API key retrieval — SSM parameter store has the key; daemon needs to read it or accept via CLI/env
- Response handling — telemetry API can return kill/pause actions; daemon should honor them
Acceptance
- Daemon sends heartbeats to configured telemetry endpoint every N seconds
- Telemetry API receives and stores heartbeats
- Frame freeze/rewind anomalies detected and reported
- Timeout (missed heartbeats) generates
OWL_EVENT_HEARTBEAT_MISSED
Problem
daemon/heartbeat.cimplements frame-count anomaly detection (freeze/rewind) and timeout tracking. It has 10 unit tests, all passing. But it's never called from the daemon's event loop or connected to the Lambda telemetry API (platform/api/handler.pyhasPOST /heartbeatready).The heartbeat tracker is dead code in production — fully implemented, tested, and unused.
What exists
daemon/heartbeat.{h,c}—owl_hb_register(),owl_hb_process(),owl_hb_check_timeout(), anomaly detectionplatform/api/handler.py—POST /heartbeatendpoint, returns action (continue/kill/pause), DynamoDB storagedaemon/main.c— no heartbeat initialization, no periodic heartbeat send, no telemetry HTTP clientWhat's missing
-lcurl) but unusedAcceptance
OWL_EVENT_HEARTBEAT_MISSED