I have a brand new test project from start.spring.io, with the following gradle file:
plugins {
id 'org.springframework.boot' version '2.6.2'
id 'io.spring.dependency-management' version '1.0.11.RELEASE'
id 'java'
}
group = 'com.example'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = '11'
repositories {
mavenCentral()
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-web'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}
test {
useJUnitPlatform()
}
When looking at dependencies, I get the following:
| | +--- org.springframework.boot:spring-boot-starter-logging:2.6.2
| | | +--- ch.qos.logback:logback-classic:1.2.9
| | | | +--- ch.qos.logback:logback-core:1.2.9
| | | | \--- org.slf4j:slf4j-api:1.7.32
| | | +--- org.apache.logging.log4j:log4j-to-slf4j:2.17.0
| | | | +--- org.slf4j:slf4j-api:1.7.25 -> 1.7.32
| | | | \--- org.apache.logging.log4j:log4j-api:2.17.0
| | | \--- org.slf4j:jul-to-slf4j:1.7.32
| | | \--- org.slf4j:slf4j-api:1.7.32
How can I completely remove log4j from the project and what should my gradle file look like? I would like to use logback exclusively.