28 lines
882 B
Markdown
28 lines
882 B
Markdown
|
|
---
|
||
|
|
id: "0003"
|
||
|
|
date: 2026-02-15
|
||
|
|
status: Accepted
|
||
|
|
supersedes:
|
||
|
|
superseded-by:
|
||
|
|
affected-paths: [taskq/notifications.py, taskq/execution.py]
|
||
|
|
affected-components: [notifications, execution]
|
||
|
|
---
|
||
|
|
|
||
|
|
# 0003 — Route all job notifications through central NotificationService
|
||
|
|
|
||
|
|
## Context
|
||
|
|
|
||
|
|
Job handlers called notification code directly, causing tight coupling and inconsistent delivery.
|
||
|
|
|
||
|
|
## Decision
|
||
|
|
|
||
|
|
All outbound notifications (webhooks, emails, events) routed through taskq.notifications.NotificationService. Handlers submit notification requests, not execute them directly.
|
||
|
|
|
||
|
|
## Consequences
|
||
|
|
|
||
|
|
Decoupled handlers from notification details. Single place to change delivery policy or add retry logic to notifications. Slightly higher latency (service batches notifications).
|
||
|
|
|
||
|
|
## Alternatives rejected
|
||
|
|
|
||
|
|
Pub/sub system rejected: overkill for current scale. Direct calls rejected: tight coupling.
|