No description
Implemented EventBus in mothership/internal/events/bus.go with: - BusEventType enum with 18 event types (MotionDetected, ZoneTransition, FallDetected, NodeConnected, etc.) - Typed EventPayload structs for all event types implementing EventType() and GetTimestamp() methods - EventBus.Publish(payload) - non-blocking fan-out to all subscribers - EventBus.Subscribe(eventType) - returns buffered channel for events - EventBus.Unsubscribe() - removes subscriber - EventBus.PublishBlocking() - blocking publish with context support - Multiple subscribers per event type with non-blocking delivery - Thread-safe with sync.RWMutex Acceptance criteria met: - Publish completes within 10ms (TestEventBusPublishWithin10ms) - Multiple subscribers receive same event (TestEventBusMultipleSubscribers) - All 18 event types have corresponding payload structs (TestAllPayloadTypes) - 17 tests covering subscribe, publish, unsubscribe, concurrent access Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .beads | ||
| .github/workflows | ||
| .marathon | ||
| dashboard | ||
| docs | ||
| firmware | ||
| mothership | ||
| tests/e2e | ||
| .dockerignore | ||
| .gitignore | ||
| .needle-predispatch-sha | ||
| .needle.yaml | ||
| docker-compose.yml | ||
| Dockerfile | ||
| PROGRESS.md | ||
| VERSION | ||