I’m using Maven2. When I look at the output of mvn dependency:tree -Dverbose I see lots of:
[INFO] +- org.springframework:spring-orm:jar:3.0.5.RELEASE:compile
[INFO] | +- (org.springframework:spring-beans:jar:3.0.5.RELEASE:compile - omitted for duplicate)
[INFO] | +- (org.springframework:spring-core:jar:3.0.5.RELEASE:compile - omitted for duplicate)
[INFO] | +- (org.springframework:spring-jdbc:jar:3.0.5.RELEASE:compile - omitted for duplicate)
[INFO] | \- (org.springframework:spring-tx:jar:3.0.5.RELEASE:compile - omitted for duplicate)
All of those are inlcuded in my pom as a dependencies as well. My question is, which is the policy to follow, leave it, excluded only version conflicts, or exclude every single transitive dependency.
I couldn’t see anything related to this in the manual.
Thanks!
Duplicity of dependecies is no issue withm maven – so you can leave this as it is.
(Every other artefacts depends on apache.logging – you don’t need to worry abou that, maven takes care for you)
You just need to solve version confilcts or you can ommit dependecies that will be provided in run environment.
Best practice is (as stated krosenvold):
And dont worry about duplicity in dependecy tree