← 返回刚才阅读的位置

知识卡片

普通读书笔记卡 · 2411.c.3.a.2

选集Saga偏向简单高吞吐

理解等级:高级

Anthology Saga采用异步、最终一致和舞蹈,是八种组合中耦合最低的一种。各服务通过消息队列推进并维护自己的本地事务,减少中央瓶颈,有利于吞吐、弹性与响应。流程上下文、异常恢复和一致性修复则分散在服务中;简单线性、错误少的管道很合适,复杂或关键流程的协调成本可能过高,必要时可用消息携带状态但会增加契约耦合。

与[[并行Saga分离事务与协调]]相比,协调器也被移除,适用边界因此不同。

这张卡片看不懂?

已有反馈 · 0 条

    还没有人提交反馈。

    在整书笔记中的位置

    原书出处 · 1 处

    • 事务Saga · 查看原书依据

      The anthology pattern uses message queues to send asynchronous messages to other domain services without orchestration, as illustrated in Figure 12-19. As you can see, each service maintains its own transactional integrity, and no orchestrator exists, forcing each domain service to include more context about the workflows they participate in, including error handling and other coordination strategies.

    参考来源

    - 位置:《Software Architecture The Hard Parts Modern Trade-Off Analyses for Distributed Architectures (Neal Ford, Mark Richards, Pramod Sadalage etc.)》第12章《Chapter 12. Transactional Sagas》(来源项目: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/ch12.xhtml) - 结论依据:原文的定义、示例或失败路径支持以下归纳:Anthology Saga采用异步、最终一致和舞蹈,是八种组合中耦合最低的一种。 其他条件结合本章同小节说明;不将模式目标当成已有运行保证。 - 原始内容:The anthology pattern uses message queues to send asynchronous messages to other domain services without orchestration, as illustrated in Figure 12-19. As you can see, each service maintains its own transactional integrity, and no orchestrator exists, forcing each domain service to include more context about the workflows they participate in, including error handling and other coordination strategies.