Correct the classpath of your application so that it contains a single, compatible version of xxx报错解决
1.背景
有时候引入包有冲突,比如在Maven项目中的不同模块多次重复引入等
这里遇到的问题是重复映入了如下包:
<dependency>
<groupId>com.baomidou</groupId>
<artifactId>mybatis-plus-boot-starter</artifactId>
<version>3.0-RELEASE</version>
</dependency>
导致启动报错如下:
.....
.....
Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2023-04-26 14:08:36.800 | | main | ERROR | o.s.b.diagnostics.LoggingFailureAnalysisReporter:40 - ***************************
APPLICATION FAILED TO START
*************************** Description: An attempt was made to call a method that does not exist. The attempt was made from the following location: com.baomidou.mybatisplus.autoconfigure.MybatisPlusAutoConfiguration.applyConfiguration(MybatisPlusAutoConfiguration.java:190) The following method did not exist: com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean.setConfiguration(Lorg/apache/ibatis/session/Configuration;)V The method's class, com.baomidou.mybatisplus.extension.spring.MybatisSqlSessionFactoryBean, is available from the following locations: jar:file:/D:/repository/com/baomidou/mybatis-plus-extension/3.1.0/mybatis-plus-extension-3.1.0.jar!/com/baomidou/mybatisplus/extension/spring/MybatisSqlSessionFactoryBean.class It was loaded from the following location: file:/D:/repository/com/baomidou/mybatis-plus-extension/3.1.0/mybatis-plus-extension-3.1.0.jar
2.问题排查步骤
步骤一:利用idea提供的工具查看依赖
步骤二:点击进去,找到最左左边红色的箭头,然后点击进去,找到那个引用,删除尝试即可
完美
Correct the classpath of your application so that it contains a single, compatible version of xxx报错解决的更多相关文章
- 整合zuul启动时报错Correct the classpath of your application so that it contains a single, compatible version of XXX
今天集成zuul与consul的时候,出现如下错误 ***************************APPLICATION FAILED TO START******************** ...
- 整合shiro出现【Correct the classpath of your application so that it contains a single, compatible version of org.quartz.Scheduler】
跑的时候出现错误: Description: An attempt was made to call the method org.quartz.Scheduler.getListenerManage ...
- Correct the classpath of your application so that it contains a single, compatible version of org.thymeleaf.spring5.SpringTemplateEngine
Error starting ApplicationContext. To display the conditions report re-run your application with 'de ...
- Correct the classpath of your application so that it contains a single, compatible version of org.springframework.util.Assert
一.问题描述 今天启动springboot工程时,报上面的错误. 二.解决方法 加入如下pom: <dependency> <groupId>org.springframewo ...
- Error configuring application listener of class 报错 解决
Error configuring application listener of class 次错误是由于工程没有贬义Class文件造成的,clean一下编译一下工程,clean之后进入项目目录查看 ...
- pip报错:解决pkg_resources.DistributionNotFound: The 'pip==7.1.0' distribution was not found and is required by the application
如果pip安装后提示依然没有pip命令,需在在添加环境变量 # vim /etc/profile 在文档最后,添加: export PATH="/usr/local/python2.7/bi ...
- 【Devops】【docker】【CI/CD】Jenkins源码管理,设置gitlab上项目的clone地址 + jenkins构建报错:Please make sure you have the correct access rights and the repository exists.
注意,如果 jenkins构建报错:Please make sure you have the correct access rights and the repository exists. 而此时 ...
- 报错:The specified datastore driver ("com.mysql.jdbc.Driver") was not found in the CLASSPATH. Please check your CLASSPATH specification, and the name of the driver.
报错背景: CDH中集成hive插件,启动报错. 报错现象: [main]: Metastore Thrift Server threw an exception... javax.jdo.JDOFa ...
- Webservice报错客户端发现响应内容类型为“application/json;charset=UTF-8”,但应为“text/xml”。
控制台对接Webservice正常,同样的方法在Web项目上报错: 客户端发现响应内容类型为“application/json;charset=UTF-8”,但应为“text/xml”.请求失败,错误 ...
- iOS---用Application Loader 上传的时候报错No suitable application records were found. Verify your bundle identifier 'xx' is correct
用Application Loader 上传的时候报错,突然发现用Application Loader的账号 竟然不是公司的账号 换成公司的账号 就可以了.
随机推荐
- 3个线程分别交替输出xyz字符,输出10遍
一位群友分享的**公司面试题 3个线程分别交替输出xyz字符,输出10遍 public class XYZ implements Runnable { private static AtomicInt ...
- 彻底解决IDEA Jrebel 错误找不到口令文件的问题
本来我的Jrebel也是好用的,突然就变成了这个样子,网上针对这个问题有很多帖子,但是每次新建项目后我都需要去解决一下这个问题,这我不能忍,经过一整天的百度和测试终于找到了原因并解决这个问题,伸手党直 ...
- Playbook条件语句
目录 Playbook条件语句 1. when的基本使用 1.1 when的基本示例 1.2比较运算符 1.3 比较运算符示例 1.4 逻辑运算符 1.5 逻辑运算符示例 2. 条件判断与block ...
- 国内外公共 DNS调研
结论 国内可以在以下DNS选择:114DNS.阿里DNS.(阿里请联系我,给我广告费^_^) 国外可以在以下DNS选择:谷歌DNS.1.1.1.1 DNS.Cisco Umbrella DNS. 国内 ...
- Golang基于Mysql分布式锁实现集群主备
背景 集群中如果需要主备,可以基于Redis.zk的分布式锁等实现,本文将介绍如何利用Mysql分布式锁进行实现. 原理 数据库中包含数据字段(此处为Master的主机名).版本号和上一次更新时间. ...
- golang执行命令 && 实时获取输出结果
背景 golang可以获取命令执行的输出结果,但要执行完才能够获取. 如果执行的命令是ssh,我们要实时获取,并执行相应的操作呢? 示例 func main() { user := "roo ...
- python json反序列化为对象
在Python中,将JSON数据反序列化为对象通常意味着将JSON格式的字符串转换为一个Python的数据结构(如列表.字典)或者一个自定义的类实例.虽然Python的标准库json模块不提供直接将J ...
- vulhub - INFOSEC PREP: OSCP
vulhub - INFOSEC PREP: OSCP 信息收集 nmap 192.168.157.0/24 nmap -sT --min-rate 10000 -p- 192.168.157.162 ...
- Java中final用法与详解
final作为Java中经常用到的关键字,了解final的使用方法是非常有必要的. 这里从final关键字在数据域.方法和类中三个方面分析final关键字的主要用法. final应用于基本数据类型 1 ...
- Linux服务器从头配置
安装配置jdk 下载 jdk jdk-8u171-linux-x64.tar.gz 将该压缩包放到/usr/local/jdk目录下然后解压(jdk目录需要自己手动创建) tar zxvf jdk-8 ...