Skip to content

[feature] RC: keep the host heartbeat and outbox delivery alive during a run #223

Closed

Description

@AetherAI3

Gap

The host exposes heartbeatHost, flushOutbox, and retry pacing, but the CLI calls flush only once during start and has no running heartbeat/delivery supervisor. Cloud liveness can go stale and later events have no delivery path.

Evidence: host primitives, one-shot CLI call, Cloud host liveness.

Acceptance

  • Bind one host lifetime to the local session: heartbeat at the agreed interval, drain bounded batches, and resume durable delivery after restart where ownership is valid.
  • Apply capped jittered backoff on transport/rate-limit failures; stop on terminal/revoked/ownership errors. No tight loop or unbounded queue growth.
  • Broker loss, viewer disconnect, and RC shutdown never stop or delay local coding work.
  • Tests exercise a 90-second simulated outage, reconnection, duplicate-safe replay, and host termination.

Scope

Observation service scheduling only; event production and QR grant handoff are separate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions