一、springboot自主加载配置信息接口 “EnvironmentPostProcessor”
官方文档如下
Allows for customization of the application's {@link Environment} prior to the application context being refreshed.
允许定制应用的上下文的应用环境优于应用的上下文之前被刷新。(意思就是在spring上下文构建之前可以设置一些系统配置)
简单来说就是在springboot启动之前就把值载入到属性工厂中。
二、外网应用不不需要在application.yml或application.properties中编写任何属性值,全由 “EnvironmentPostProcessor”接口的实现类来加载。