总结: 主要原理 通过 SPI、 配置注解@Import @Configuration 条件注解@ConditionalXXX 、 Spring的Bean生命周期拓展点xxxPostProcessor 实现 核心流程如下