Enhancement

When org.springframework.boot:spring-boot-starter-logging:jar:2.5.5:test is added, it also brings in org.apache.logging.log4j:log4j-to-slf4j:jar:2.14.1:test, which has a transitive dependency on org.apache.logging.log4j:log4j-api:jar:2.14.1:test.

Since SLF4J and Logback is used, shouldn't it rather be: org.slf4j:log4j-over-slf4j:jar:1.7.32? The difference is:

log4j-to-slf4j "The Apache Log4j binding between Log4j 2 API and SLF4J." vs. log4j-over-slf4j "Log4j implemented over SLF4J"

See: http://www.slf4j.org/images/legacy.png

Here is the output of the Maven dependency tree command:

[INFO] | | | +- org.springframework.boot:spring-boot-starter-logging:jar:2.5.5:test [INFO] | | | | +- ch.qos.logback:logback-classic:jar:1.2.6:test [INFO] | | | | | - ch.qos.logback:logback-core:jar:1.2.6:test [INFO] | | | | +- org.apache.logging.log4j:log4j-to-slf4j:jar:2.14.1:test [INFO] | | | | | - org.apache.logging.log4j:log4j-api:jar:2.14.1:test [INFO] | | | | - org.slf4j:jul-to-slf4j:jar:1.7.32:test [INFO] | | | +- jakarta.annotation:jakarta.annotation-api:jar:1.3.5:test [INFO] | | | +- org.springframework:spring-core:jar:5.3.10:test [INFO] | | | | - org.springframework:spring-jcl:jar:5.3.10:test

Comment From: wilkinsona

The two artifacts allow logging that's performed using the Log4j API to be routed into SLF4J, but for different versions of that API. log4j-over-slf4j is for Log4J 1.x. log4j-to-slf4j is for Log4j 2.x.