简体   繁体   中英

Dependency Conflict and can't find jar to resolve that

I have a project with two versions of the same jar and the problem is that it is causing a jar conflict.

 [WARNING] org.apache.cxf.transports.http.configuration.package-info scanned from multiple locations: jar:file:///private/var/folders/rw/9_fr4s6s01d5vcykl3fqkd7d3j59v0/T/jetty-0.0.0.0-0-attache-api-rest.war-_api-any-2999199381910928390.dir/webapp/WEB-INF/lib/cxf-rt-transports-http-3.1.12.jar./org/apache/cxf/transports/http/configuration/package-info,class: jar:file.///private/var/folders/rw/9_fr4s6s01d5vcykl3fqkd7d3j59v0/T/jetty-0.0.0.0-0-attache-api-rest.war-_api-any-2999199381910928390.dir/webapp/WEB-INF/lib/cxf-rt-transports-http-3.1.4.jar!/org/apache/cxf/transports/http/configuration/package-info.class

I wanted to remove the previous version and I know how to remove it using exclusions, but I am not able to find the cxf-rt-transports-http-3.1.4.jar in pom.xml dependency hierarchy so that I could found out from where this transitive dependency is actually coming.

Edit: Screenshot of dependency Hierarchy in STS4

You can try to find the dependency from eclipse dependency graph, Below is the SS to search for a specific jar in the project.

在此处输入图像描述

If there is more than one version of a jar, you would be seeing 2 different versions of the jar with a different parent library. You can exclude the other from there by right-clicking on it and selecting exclude option.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM