当前位置:网站首页>idea jar包冲突排查
idea jar包冲突排查
2022-07-02 12:28:00 【lvhui321】
在Java项目开发中,jar包冲突是比较常见的问题,快速定位冲突位置是非常重要的。传统方式定位主要采用idea自带的Diagrams插件,由于jar依赖是以图表展示的,导致引用错综复杂,往往排查费时费力;今天我们来介绍一个更利于快速定位jar包冲突的插件Maven Helper。
1.Maven Helper安装,下载Maven Helper
2.Maven Helper安装完成
3.Maven Helper使用,打开pom.xml文件,点左下角Dependency Analyzer
4. Conflicts展示冲突,冲突相关的jar在右侧展示,如果右侧有冲突,可以右键Exclude进行排除
5.All Dependencies as List 展示所有依赖项列表,Show GroupId 展示jar包GroupId,Show Size 展示jar包大小,All Dependencies as Tree 展示jar包依赖树。
6.jar包冲突常见的异常
出现以下异常时,若clean jar包后还是无法成功启动项目,就可以考虑是否出现jar包冲突。NoDefClassException、ClassNotFoundException、NoSuchMethodError、NoSuchFieldError;
这些异常可能是引用了之前旧版的jar包,新版本的jar升级并deploy之后,类的路径、名字、字段有变化,导致无法加载到想要的类或方法。
边栏推荐
猜你喜欢
Introduction to Dynamic Planning II (5.647.62)
Introduction to dynamic planning I, BFS of queue (70.121.279.200)
Traversal before, during and after binary tree
《大学“电路分析基础”课程实验合集.实验五》丨线性有源二端网络等效电路的研究
智联招聘的基于 Nebula Graph 的推荐实践分享
Experiment collection of University "Fundamentals of circuit analysis". Experiment 6 - observation and measurement of typical signals
Why does the system convert the temp environment variable to a short file name?
[leetcode] 417 - Pacific Atlantic current problem
How to use percona tool to add fields to MySQL table after interruption
【Experience Cloud】如何在VsCode中取得Experience Cloud的MetaData
随机推荐
如何實現十億級離線 CSV 導入 Nebula Graph
2279. 装满石头的背包的最大数量
Experiment collection of University "Fundamentals of circuit analysis". Experiment 7 - Research on sinusoidal steady-state circuit
Two traversal sequences are known to construct binary trees
Folium, diagnosis and close contact trajectory above
6095. Strong password checker II
PyObject 转 char* (string)
数字藏品系统开发(程序开发)丨数字藏品3D建模经济模式系统开发源码
[leetcode] 1020 number of enclaves
愛可可AI前沿推介(7.2)
《大学“电路分析基础”课程实验合集.实验四》丨线性电路特性的研究
爱可可AI前沿推介(7.2)
Postgressql stream replication active / standby switchover primary database no read / write downtime scenario
beforeEach
/Bin/ld: cannot find -llz4
如何实现十亿级离线 CSV 导入 Nebula Graph
SQL FOREIGN KEY
/bin/ld: 找不到 -lxml2
Introduction to dynamic planning I, BFS of queue (70.121.279.200)
Experiment collection of University "Fundamentals of circuit analysis". Experiment 6 - observation and measurement of typical signals