ADR 0005: Friendship stream consumers
Status
Accepted.
Context
After phase 3, social-service published friendship events that nobody production-ready consumed. The product needed an in-app notification for friend requests and feed activity when a request is accepted.
Decision
- notification-service consumes
splick.streams.social.friend-request-sentandfriend-request-accepted. - feed-service consumes
friend-request-accepted. - Each service has its own consumer group and dedupes on envelope
eventId. - Side effects persist in
notification.notificationsandfeed.feed_activities.
Groups:
notification-service.friend-request-sentnotification-service.friend-request-acceptedfeed-service.friend-request-accepted
Runtime transport remains STREAMS.
Consequences
Friendship events have real side effects. Notification and feed can evolve their read models without social importing their tables. More consumer groups must be watched for lag.
Rollback
Stop the consumer, leave the stream intact, fix the handler, replay. Do not change the social event contract to "undo" a bad consumer.