为什么危险
- 爆炸半径大:sip-mac-data 被 21 个上游服务依赖,它一处故障 / 一次不兼容变更 = 全局波及。
- 变更牵制重:作为共享底座,任何接口改动都需协调 21 方同步回归,迭代慢、出错概率高。
- 容量瓶颈:所有读写汇聚点,流量高峰易成性能瓶颈,且难以独立扩容。
sip-mac-data 的 21 个真实消费者
sip-mac-authsip-mac-auth-sdksip-mac-awsip-mac-award-distributionsip-mac-codesip-mac-code-accessorsip-mac-code-relaysip-mac-crssip-mac-crs-asyncsip-mac-data-relaysip-mac-data-scopesip-mac-dmsip-mac-download-centersip-mac-gatewaysip-mac-openapisip-mac-promotionsip-mac-reportsip-mac-special-activitysip-mac-warnsip-mac_dcentersip-operation-log
其他枢纽同理存在单点风险:sip-mac-promotion(7), sip-mac-receive(6), sip-mac-data-relay(4), sip-mac-openapi(4), sip-mac-report(4)。治理时优先拆最高频、最稳定的读场景。
治理建议
- 读写分离 / CQRS:把高频读场景从 sip-mac-data 拆出只读服务,核心写库减负。
- 缓存化(Redis):消费方 / 网关层加缓存,data 抖动时不直接雪崩。
- 熔断降级(Sentinel / Resilience4j):消费方对 data 的 Dubbo 调用加熔断 + 超时,快速失败而非线程堆积。
- 拆子域:按业务域(会员 / 商品 / 订单…)将 data 拆分为多个专项服务,缩小爆炸半径。
- 契约版本化:data 的 Dubbo 接口变更走兼容版本号,避免"牵一发而动全身"。