Springboot加载日志模块顺序
Springboot加载日志模块 Spring jcl Spring jcl 是Springboot连接SLF4J的基础包,实现了对Log4j 2.x API是否存在,以及Spring框架类路径中的SLF4J 1.7api。 ServiceLoader 通过配置寻找接口的实现类,实现类的jar包的META-INF下新建一个文件夹services,并在services下新建一个文件,以接口的全限定名为文件名,内容为实现类的全限定名。 参考链接: https://www.jianshu.com/p/7601ba434ff4 https://blog.csdn.net/shi2huang/article/details/80308531 Log4j获取ConfigurationFactory 核心代码 String ALL_TYPES = "*"; for (final ConfigurationFactory factory : getFactories()) { final String[] types = factory.getSupportedTypes(); if (types !...