You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ivy-user@ant.apache.org by "Ahire, Manjiri" <ma...@blackrock.com> on 2015/05/15 17:19:54 UTC

Regarding Apache Ivy Dependency Tree order

Hi,

I am trying to understand how Ivy when used in configuration with Ant, builds the dependency tree / manifest.mf file at runtime?
May be you can point me to documentation. I have been facing a spring version conflict issue and tried to use override, force, conflict-manager stuff and it didn’t work for me. (it works in Eclispe but not when I deploy)

Also, just so you know the conflicting jar is not named as Spring , its some third party jar in which those people have packaged the spring classes. Can’t get rid of it.

Please let me know. Appreciate it.

Thanks,
Manjiri.

This message may contain information that is confidential or privileged. If you are not the intended recipient, please advise the sender immediately and delete this message. See http://www.blackrock.com/corporate/en-us/compliance/email-disclaimers for further information.  Please refer to http://www.blackrock.com/corporate/en-us/compliance/privacy-policy for more information about BlackRock’s Privacy Policy.
For a list of BlackRock's office addresses worldwide, see http://www.blackrock.com/corporate/en-us/about-us/contacts-locations.

© 2015 BlackRock, Inc. All rights reserved.

Re: Regarding Apache Ivy Dependency Tree order

Posted by Antoine Levy Lambert <an...@gmx.de>.
Hello Manjiri,

as far as I am aware ant is able to create the classpath attribute for a manifest file using a manifestclasspath task.

I understand that the application that you are working on is depending upon a jar file which packages an implementation of spring which you do not want to use.

Assuming this jar file is called badspring.jar here is what I would do 

<manifestclasspath property=“myclasspath”>
    <classpath>
         <fileset dir=“lib”>
             <include name=“*.jar”/>
            <exclude name=“badspring.jar”/>
        </fileset>
       <pathelement location=“lib/badspring.jar”/>
   </classpath>
</manifestclasspath>

This way you make sure that lib/badspring.jar is at the end of the classpath element in the manifest.

Another suggestion would be to repackage badspring.jar without the offending classes and store that in your repository under a different org than the original.

Regards,

Antoine

[1] http://ant.apache.org/manual/Tasks/manifestclasspath.html
On May 15, 2015, at 11:19 AM, Ahire, Manjiri <ma...@blackrock.com> wrote:

> Hi,
> 
> I am trying to understand how Ivy when used in configuration with Ant, builds the dependency tree / manifest.mf file at runtime?
> May be you can point me to documentation. I have been facing a spring version conflict issue and tried to use override, force, conflict-manager stuff and it didn’t work for me. (it works in Eclispe but not when I deploy)
> 
> Also, just so you know the conflicting jar is not named as Spring , its some third party jar in which those people have packaged the spring classes. Can’t get rid of it.
> 
> Please let me know. Appreciate it.
> 
> Thanks,
> Manjiri.
> 
> This message may contain information that is confidential or privileged. If you are not the intended recipient, please advise the sender immediately and delete this message. See http://www.blackrock.com/corporate/en-us/compliance/email-disclaimers for further information.  Please refer to http://www.blackrock.com/corporate/en-us/compliance/privacy-policy for more information about BlackRock’s Privacy Policy.
> For a list of BlackRock's office addresses worldwide, see http://www.blackrock.com/corporate/en-us/about-us/contacts-locations.
> 
> © 2015 BlackRock, Inc. All rights reserved.