知识卡片
防腐层隔离外部模型语义
防腐层把外部系统的概念和操作翻译为本地领域模型的表达,对本地客户提供本地语言的功能,再通过外部系统现有接口交互。它保护本地模型不被异质模型逐步改写;翻译可按实际调用方向往返进行,通常不要求外部系统配合改造。
它处理的是概念语义,不是网络消息发送本身。协议、平台和数据格式适配可能同时存在,却不能替代模型翻译。
这张卡片看不懂?
这张卡片已通过人工审查,不再接受失败反馈。
已有反馈 · 0 条
还没有人提交反馈。
在整书笔记中的位置
原书出处 · 1 处
- 原书第14章|Anticorruption Layer · 查看原书依据
Create an isolating layer to provide clients with functionality in terms of their own domain model. The layer talks to the other system through its existing interface, requiring little or no modification to the other system. Internally, the layer translates in both directions as necessary between the two models.
参考来源
- 位置:《Domain-Driven Design: Tackling Complexity in the Heart of Software》第109章《Anticorruption Layer》(源文件:_epub-src/0321125215_ch14lev1sec8.html;单元01)
- 结论依据:原文定义隔离层、本地模型接口、经外部既有接口交互及双向翻译,并区分传输与语义。
- 原始内容:Create an isolating layer to provide clients with functionality in terms of their own domain model. The layer talks to the other system through its existing interface, requiring little or no modification to the other system. Internally, the layer translates in both directions as necessary between the two models.