Determine where each maven dependency(jar) is called and remove unused
The problem: I have to work on an existing maven project which has a lot of unnecessary dependencies.It's source code is too chaotic(really old project) to determine where each dependency is needed. Is there a way to check where each dependency is called, so I can remove it, or alter the code to not need this specific dependency without having to go through the entire source code?
mvn dependency:tree to see how each dependency is being pulled in. it will give you a tree view of how each dependency is being used. This is how i remove unwanted dependencies.