Skip to content

Relay backend: event-log fast-path in front of the roster-reconciliation exit watcher #74

Description

@willwashburn

The relay backend detects agent exits by reconciling tracked agents against the engine roster (15s poll) because the hosted engine emits no push event on exit. Once AgentWorkforce/relaycast#273 (durable agent.exited event) lands and cast.agentrelay.com runs an engine that carries it (AgentWorkforce/relaycast-cloud#33), add a fast-path:

  • consume agent.exited (and node.status.offline) from the agent event stream / durable event log with a persisted cursor (FileStateStore)
  • keep the reconciliation poll as the belt-and-braces detector at a longer interval
  • carry the exit reason through so isCompletionReason gets task-exit fidelity instead of routing everything through the PR probe

Blocked on the two upstream issues above.

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions