I have the following dependencies in my build.gradle file.
compile \'org.slf4j:slf4j-api:1.7.25\'
compile group: \'org.apache.logging.log4j\', name: \'log4j-
Correct way to configure log4j2 in spring boot is like this:
dependencies {
compile 'org.springframework.boot:spring-boot-starter-web'
compile 'org.springframework.boot:spring-boot-starter-log4j2'
}
configurations {
all {
exclude group: 'org.springframework.boot', module: 'spring-boot-starter-logging'
}
}
It's explained in the documentation.