知识卡片
建库前确认服务不合适
新建库适合已有方案无法满足的通用需求,或本地执行、性能、语言集成使远程服务不自然的情形。若只是编码偏好、对工程师不信任或追求零重复,应优先考虑现有 SDK、服务或局部实现。
这张卡片看不懂?
这张卡片的反馈已满 10 条,暂时无法继续提交。
已有反馈 · 0 / 10 条
还没有人提交反馈。
原书出处
参考来源
- 位置:《Principles of Software Architecture Modernization》第4章《Anti-Patterns: Internal Shared Libraries》(源文件:`_epub-src/OPS/ch04.xhtml`,归一化正文 [42010:46195))
- 结论依据:原文区分建库合理条件和不合理动机,强调自定义问题、服务不自然及有效复用,而不是单纯偏好。
- 原始内容:Service will not be natural : A service would be too slow or is the completely wrong model, i.e. you cannot abstract the Spring IoC / dependency injection core framework into a remote service, this would add complexity and overheads with no benefits.