maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ron Wheeler <rwhee...@artifact-software.com>
Subject Re: Transitive Dependencies for Unused Artifact
Date Fri, 16 Mar 2012 12:16:42 GMT
Exclude is your friend.
When declaring ArtifactX as a dependency exclude log4j and include the 
version of log4j that you need as a dependency.

As long as ArtifactX will work with your version of log4j, you are OK.

Ron

On 16/03/2012 6:11 AM, kdobrik wrote:
> Hi guys,
> I have the following use case. Project with several modules that inherit a
> parent POM. Let's say we have 5 modules (e.g. A, B, C, D, E) . In 3  of them
> (e.g. A-C) we need ArtifacX. Let's say ArtifacX has a transitive dependency
> to log4j version X.
>
> My question is:
> If I move ArtifacX dependency into the parent POM (inherited by all 5
> modules!), what will happen with the modules that do not need ArtifacX (e.g.
> D and E), but make use of log4j? Should I expect that it is possible to
> pollute them with the transitive dependency to log4j (let's say v.Y)
> introduced by ArtifacX into the parent POM? Do not forget that in fact D and
> E do not need ArtifacX, but need log4jX?
>
> Thank you in advance,
> kdobri
>
> --
> View this message in context: http://maven.40175.n5.nabble.com/Transitive-Dependencies-for-Unused-Artifact-tp5570805p5570805.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>


-- 
Ron Wheeler
President
Artifact Software Inc
email: rwheeler@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102



Mime
View raw message