知识卡片
退订补偿需要恢复信息
针对[[退订局部提交留下残态]],请求编排方案可让已成功的参与者执行反向更新:重插客户资料,把合同remove_date恢复为零。编排器须保存重插所需信息,并检查创建动作是否触发初始化等副作用;反向业务操作不等于数据库回滚。补偿本身失败仍可能需要人工修复,因此不能用补偿承诺跨服务隔离或无条件原子性。
这张卡片看不懂?
这张卡片已通过人工审查,不再接受失败反馈。
已有反馈 · 0 条
还没有人提交反馈。
在整书笔记中的位置
原书出处 · 1 处
- 数据所有权与分布式事务 · 查看原书依据
issue a compensating update to reinsert the customer in the Profile table and set the remove_date column in the Contract table back to zero. This would require the orchestrator to have all of the necessary information to reinsert the customer, and that no side effects occur when creating a new customer (such as initializing the billing information or support contracts).
参考来源
- 位置:《Software Architecture: The Hard Parts》第09章《数据所有权与分布式事务》(来源项目:book-sources;源文件:extracted/Software Architecture The Hard Parts Modern Trade-Off Analyses for Distributed Architectures (Neal Ford, Mark Richards, Pramod Sadalage etc.)/_epub-src/OEBPS/ch09.xhtml)
- 结论依据:所引连续原文给出本卡机制或取舍;条件与示例结合本节已读上下文解释。
- 原始内容:issue a compensating update to reinsert the customer in the Profile table and set the remove_date column in the Contract table back to zero. This would require the orchestrator to have all of the necessary information to reinsert the customer, and that no side effects occur when creating a new customer (such as initializing the billing information or support contracts).