Map reliability, operator UX, and spend-control follow-ons onto epics 1–9 so worker, webhooks, and fleet work have bead-scale task briefs. Co-authored-by: Cursor <cursoragent@cursor.com>
2 KiB
2 KiB
| kind | slug | title | plan_slug | epic_slug | status | priority | tenant_id | owner | cursor_todo_id | updated_at |
|---|---|---|---|---|---|---|---|---|---|---|
| task | convoy-activity-feed-sse | Live convoy activity feed (SSE) | automation-foundation | fleet-dashboard | draft | P2 | global | unassigned | null | 2026-08-03 |
Task summary
Real-time activity stream from convoy_events for mission control and fleet dashboard — research/build/gate/health events without full page refresh.
Description
Benchmark: Autensa live activity feed (SSE). Echodo already appends convoy_events for role completion, transitions, and (future) health events — this task exposes them as a subscription surface.
Transport
- Prefer Next.js Route Handler
GET /api/convoys/activity/streamwith SSE (workspace-scoped via session) - Alternative: tRPC subscription if infra already supports it — pick one, document in ADR addendum
Event types surfaced
role_complete,transition,health,gate_action- Payload:
convoy_id,title,event_type,role,outcome,occurred_at,estimated_cost_usd(when present)
UI
- Mission control: collapsible Activity strip (last 20 events for current workspace)
- Fleet dashboard: global feed with product/repo filter
- Fallback: React Query poll every 30s when SSE unavailable
Dependencies
- Epic 4
convoy_events(shipped) - Task-orchestrator-auto-nudge for health events (soft — feed works without it)
Subtasks
- SSE route with workspace membership check
convoy_eventstail query + fan-out on insert (LISTEN/NOTIFY or short poll server-side)ActivityFeedclient component- Rate limit / connection cap per user
Estimation
M
Acceptance criteria
- New
role_completeevent appears in mission control within 5s without refresh - User cannot subscribe to another workspace's events
- Connection closes cleanly on navigation
Links
- Epic:
./Epic-fleet-dashboard.md