The structures of large systems tend to disintegrate during development, qualitatively more so than with small systems. Organizations which design systems are constrained to produce designs which are copies of the communication structures of these organizations. 根据康威定律:大的系统总是在发展中趋于分解、重组,以达到系统架构和人员结构的某种同态。为了解决idleapi存在的各种问题,我们决定对它进行拆分。拆分过程中,有几个问题必须要提前考虑清楚:1. 拆分的产物是什么?是按业务域划分的传统的单体应用,还是以业务接口为单位的FaaS函数?2. 拆分过程中,业务代码是全部重写还是复用?如何处理冗余的业务代码?3. 业务的配置、监控、告警如何迁移?4. 如何快速验证?5. 如何平滑灰度?如何回滚?业务迁移过程中,新的需求如何处理?6. 应用上线后,是否有措施防止再次出现应用/Faas膨胀问题?上述几个问题是拆分流程的关键点,决定着拆分方案能否成功的落地执行。接下来我们逐个分析下。