知识卡片
战术分叉以删除代提取
战术分叉先按目标服务复制完整单体,各团队逐步删除不需要的功能,而不是从混乱代码中拉出一块后不断追逐依赖。编译与测试帮助判断能否删去代码。适合组件边界难辨、需要快速隔离关键系统的场景;目标服务范围必须预先决定。
结构图:
flowchart TD
A[完整单体] --> B[复制给团队一]
A --> C[复制给团队二]
B --> D[逐步删除非目标功能]
C --> E[逐步删除非目标功能]
D --> F[粗粒度服务一]
E --> G[粗粒度服务二]
这张卡片看不懂?
这张卡片已通过人工审查,不再接受失败反馈。
已有反馈 · 0 条
还没有人提交反馈。
在整书笔记中的位置
原书出处 · 1 处
- 选择架构分解方法 · 查看原书依据
Each team receives a copy of the entire codebase, and they start deleting (as illustrated previously in Figure 4-7) the code they don’t need rather than extract the desirable code. Developers often find this easier in a tightly coupled codebase because they don’t have to worry about extracting the large number of dependencies that high coupling creates. Rather, in the deletion strategy, once functionality has been isolated, delete any code that doesn’t break anything.
参考来源
- 位置:《Software Architecture: The Hard Parts》第4章《选择架构分解方法》(来源项目: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/ch04.xhtml)
- 结论依据:原文的定义、比较或案例支持“战术分叉先按目标服务复制完整单体,各团队逐步删除不需要的功能,而不是从混乱代码中拉出一块后不断追逐依赖”;正文据此解释其用途与适用边界。
- 原始内容:Each team receives a copy of the entire codebase, and they start deleting (as illustrated previously in Figure 4-7) the code they don’t need rather than extract the desirable code. Developers often find this easier in a tightly coupled codebase because they don’t have to worry about extracting the large number of dependencies that high coupling creates. Rather, in the deletion strategy, once functionality has been isolated, delete any code that doesn’t break anything.