Spring-Boot logging with log4j2?
问题 I'm using spring-boot-starter , and would like to configure log4j2.xml to log asynchron + different content to different logfiles. I created the log4j2 file, but Spring still uses the spring-boot default logging. How can I switch the logging? 回答1: I've a better way: Exclude logback logger: <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter</artifactId> <exclusions> <exclusion> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter