Issue
I am building a Java (web) application with Maven and Eclipse.
When I look inside my .war
file I can see the following logging libraries there:
log4j-1.2.14.jar
log4j-1.2.17.jar
slf4j-api-1.7.5.jar
slf4j-log4j12-1.7.5.jar
I did not declared these libraries in my pom.xml
, so they probably are transitive dependencies (i.e. dependencies of my dependencies).
How can I find out which of my dependencies depend on these libraries?
I tried to use the mvn dependency:tree
plugin, but it does not show any of these .jar
s.
In Eclipse, the Java Resources > Libraries > Maven Dependencies
node does not show them either. Though, curiously, it shows other transitive dependencies of my project.
Solution
Open pom.xml
in Eclipse and go to Dependency Hierarchy
tab
Answered By - Evgeniy Dorofeev
Answer Checked By - Dawn Plyler (JavaFixing Volunteer)