PDA

View Full Version : Ivy configuration



kierann
May 19th, 2009, 12:22 PM
I am attempting to setup an ivy configuration for our projects that will work seamlessly with SpringSource's Enterprise Bundle Repository, but not sure I got it right. I tried to model it after the dm Server samples: using "provided->compile" for bundles that don't come standard with dm Server and "dm-server-provided->compile" for bundles that do. The problem I'm running into is with importing the org.springframework.security.providers.cas bundle. The "provided->compile" ivy configuration causes the resolve to bring in the spring library (which is not necessary as it comes with dm Server). Is there a more appropriate way to work with the Enterprise Bundle Repository using ivy?

Here is the line in the ivy file:
<dependency org="org.springframework.security" name="org.springframework.security.providers.cas" rev="2.0.4.A" conf="provided->compile" />

Thank you.

Andy Wilkinson
May 19th, 2009, 01:27 PM
Unfortunately, this is a general problem with transitive dependency management and there's no nice way to get the behaviour that you'd like.

In your situation, I think I'd use a nested <exclude> in your Spring Security dependency declaration to stop it from pulling in the various Spring jars upon which Spring Security depends.

kierann
May 19th, 2009, 02:56 PM
Thank you for your quick reply. That will do the trick.