spring boot 配置文件加载顺序详解

1.项目内配置文件 spring boot 启动会扫描以下位置的application.properties或者application.yml文件 作为Spring boot的默认配置文件 –file:./config/ –file:./ –classpath:/config/ –classpath: 以上是按照优先级从高到低的顺序,所有位置的文件都会被加载,高优先级配置内容会覆盖低优先级配置内容
相关文章
相关标签/搜索