知识卡片
贫血事件缺少变更上下文
原书个人资料更新例中,“profile_updated”只带客户ID,订阅者即使查当前数据库,也可能不知道改的是地址还是姓名,更看不到变更前值,无法决定后续动作。事件应携足以解释状态变化的上下文,例如更新字段与前后值;无需把整条记录所有字段都塞入载荷。[[事件载荷按数据与键取舍]]
这张卡片看不懂?
这张卡片已通过人工审查,不再接受失败反馈。
已有反馈 · 0 条
还没有人提交反馈。
在整书笔记中的位置
原书出处 · 1 处
- Event-Driven Architecture Style · 查看原书依据
An anemic event is a derived event with a payload that doesn’t contain enough information to help the event processor make decisions
参考来源
- 位置:《Fundamentals of Software Architecture》原书第15章《Event-Driven Architecture Style》(阅读计划第18项,单元09;源文件:`OEBPS/ch15.html`)
- 结论依据:资料变更事件缺少前后值。
- 原始内容:An anemic event is a derived event with a payload that doesn’t contain enough information to help the event processor make decisions