[BEL] 双路径通知、投递事实与供应商故障切换 #185

Open
opened 2026-09-01 10:04:33 +08:00 by ila · 0 comments
Owner

状态

待实施(规划已确认;前置 #182/#183/#184 与 #176 通知门禁未满足)

基本信息

  • 所属 Epic:#7
  • 所属 MVP:#174
  • 规划来源:#173
  • 主项目:Bell
  • 主 agent:Bell agent
  • 前置:#182 原型确认、#183/#184 验收;供应商和第二路径依赖 #176

目标

实现本地 Web/声光与短信或语音的双路径通知适配、供应商健康、故障切换、重试/最终失败和 sent/delivered/seen/ack 分离的投递事实;真实外发必须通过显式试点开关和合法测试收件人。

非目标

  • 不在工单/日志/Git保存真实号码、token 或供应商密钥
  • 不把 sent/delivered/seen 当作 ack
  • 不让客户平台接管 Bell Alert 状态机
  • 供应商未确认时只实现模拟适配器和禁用态

精确 write_paths

  • Bell/server/app/bell/notification/
  • Bell/server/app/bell/delivery/
  • Bell/server/app/bell/provider/
  • Bell/server/app/bell/router/notification.go
  • Bell/server/app/bell/router/delivery.go
  • Bell/server/cmd/migrate/migration/version/2026090112000_notification_delivery.go
  • Bell/server/cmd/migrate/migration/version/2026090112000_notification_delivery_test.go
  • Bell/ui/src/api/bell/notification.js
  • Bell/ui/src/api/bell/delivery.js
  • Bell/ui/src/views/bell/notifications/
  • Bell/ui/src/views/bell/deliveries/
  • Bell/server/tests/bell_notification/
  • Bell/config/notification.env.example

除上述路径外禁止写入;新增路径必须先更新工单并取得确认。

验收标准

  • 默认禁用真实外发且没有默认供应商秘密
  • 两条路径独立记录尝试、结果、回执能力和失败原因
  • 一条路径失败时按确认策略切换且不伪造成功
  • 不支持回执、未知、可重试和最终失败明确区分
  • 投递快照固化收件人脱敏引用、通道、排班和升级策略版本
  • 真实外发只能在 #176 确认的门禁和合法测试对象上验收

风险与回退

从当前 dev 建立独立任务分支;实施前复核前置和线上原型版本。状态迁移、通知和排班属于高风险业务事实,发现语义变化或客户参数缺失时停止。回退停用新增策略/Worker/通道,不删除联系人、排班版本、投递、Alert 或审计历史。

文档影响

更新 Bell Product-Requirements、Architecture-and-Code-Map、Business-Rules-and-Glossary、Deployment-and-Operations、Local-Development-and-Verification、Troubleshooting。

## 状态 待实施(规划已确认;前置 #182/#183/#184 与 #176 通知门禁未满足) ## 基本信息 - 所属 Epic:#7 - 所属 MVP:#174 - 规划来源:#173 - 主项目:Bell - 主 agent:Bell agent - 前置:#182 原型确认、#183/#184 验收;供应商和第二路径依赖 #176 ## 目标 实现本地 Web/声光与短信或语音的双路径通知适配、供应商健康、故障切换、重试/最终失败和 sent/delivered/seen/ack 分离的投递事实;真实外发必须通过显式试点开关和合法测试收件人。 ## 非目标 - 不在工单/日志/Git保存真实号码、token 或供应商密钥 - 不把 sent/delivered/seen 当作 ack - 不让客户平台接管 Bell Alert 状态机 - 供应商未确认时只实现模拟适配器和禁用态 ## 精确 write_paths - `Bell/server/app/bell/notification/` - `Bell/server/app/bell/delivery/` - `Bell/server/app/bell/provider/` - `Bell/server/app/bell/router/notification.go` - `Bell/server/app/bell/router/delivery.go` - `Bell/server/cmd/migrate/migration/version/2026090112000_notification_delivery.go` - `Bell/server/cmd/migrate/migration/version/2026090112000_notification_delivery_test.go` - `Bell/ui/src/api/bell/notification.js` - `Bell/ui/src/api/bell/delivery.js` - `Bell/ui/src/views/bell/notifications/` - `Bell/ui/src/views/bell/deliveries/` - `Bell/server/tests/bell_notification/` - `Bell/config/notification.env.example` 除上述路径外禁止写入;新增路径必须先更新工单并取得确认。 ## 验收标准 - [ ] 默认禁用真实外发且没有默认供应商秘密 - [ ] 两条路径独立记录尝试、结果、回执能力和失败原因 - [ ] 一条路径失败时按确认策略切换且不伪造成功 - [ ] 不支持回执、未知、可重试和最终失败明确区分 - [ ] 投递快照固化收件人脱敏引用、通道、排班和升级策略版本 - [ ] 真实外发只能在 #176 确认的门禁和合法测试对象上验收 ## 风险与回退 从当前 `dev` 建立独立任务分支;实施前复核前置和线上原型版本。状态迁移、通知和排班属于高风险业务事实,发现语义变化或客户参数缺失时停止。回退停用新增策略/Worker/通道,不删除联系人、排班版本、投递、Alert 或审计历史。 ## 文档影响 更新 Bell Product-Requirements、Architecture-and-Code-Map、Business-Rules-and-Glossary、Deployment-and-Operations、Local-Development-and-Verification、Troubleshooting。
ila added the kind/taskproject/bellpriority/p0 labels 2026-09-01 10:04:33 +08:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: ila/yovision#185