First of all, there must be a little compatibility problem with the version.
So I went into the project and looked at the dependencies tree, CD into the project directory, MVN Dependency:tree
I saw that my project was originally 1.5.9 and now 2.0.1 the difference between ORG.SLF4J's dependence
"1.5.9.release"
"2.0.1.release"
So the problem is simple, I will use the original log dependency all manually add 1.7.25 version
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-to-slf4j</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.25</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>log4j-over-slf4j</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
</dependency>
Because the projects are all logback, so it's okay to rule out log4j.
Spring boot project upgraded to 2.0.1, prompting Java.lang.ClassNotFoundException:org.apache.log4j.Logger error