问题说明,依赖冲突,循环依赖
方法一:
(mybatis-plus版本为3.1.2)
可能是系统中的mybatis丶mybatis-spring版本与mybatis-plus版本差距太大,导致引入mybatis-plus后有依赖冲突,未升级前mybatis为3.4.6,mybatis-spring为1.3.2。升级版本后系统可正常启动。
(ps:如果系统中没有调用mybatis丶mybatis-spring下的东西,那么之间删除即可)
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.5.4</version>
</dependency>
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis-spring</artifactId>
<version>2.0.4</version>
</dependency>
方法二:以下两个依赖会冲突,有了 mybatis-plus-boot-starter,就不需要 spring 自己的 mybatis-spring-boot-starter 了。
<!--删除即可-->
<dependency>
<groupId>org.mybatis.spring.boot</groupId>
<artifactId>mybatis-spring-boot-starter</artifactId>
</dependency>