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 jeff <je...@yahoo.com> on 2007/05/02 21:19:52 UTC

resetting resolvers / re-configuring ivy

i have a multi-level project. there is a top level build.xml that essentially sets up dependencies for and calls module build.xml's ...

one of the modules is "dependencies", and it's job is to simply create a local file system repo for the rest of the modules to use.

the problem is that when the top level build.xml calls dependencies, that module calls ivy:configure with a particular ivy settings that includes many resolvers ...

then each module calls ivy:configure pointing to an ivy settings that just points to the locally built repo.

the problem is that since this is all happening from within a single "ant" call, the ivy settings, and the resolvers set up when the top level build call the dependencies module are still in effect when the other modules are built, even though ivy:configure was called again w/ the simpler set of resolvers. the results is that i see errors like :

[ivy:retrieve] :: problems summary ::
[ivy:retrieve] :::: ERRORS
[ivy:retrieve]  unknown resolver ibiblio-maven2
[ivy:retrieve]  unknown resolver ibiblio-maven2
...

the build still succeeds, but i'd sure like to make those errors go away.

the root problem i guess is that i want to re-configure ivy from within a single ant call. is this possible?



       
---------------------------------
Ahhh...imagining that irresistible "new car" smell?
 Check outnew cars at Yahoo! Autos.

Re: resetting resolvers / re-configuring ivy

Posted by jeff <je...@yahoo.com>.
thank you for the very comprehensive answer :)

Xavier Hanin <xa...@gmail.com> wrote: On 5/2/07, jeff  wrote:
> i have a multi-level project. there is a top level build.xml that essentially sets up dependencies for and calls module build.xml's ...
>
> one of the modules is "dependencies", and it's job is to simply create a local file system repo for the rest of the modules to use.
>
> the problem is that when the top level build.xml calls dependencies, that module calls ivy:configure with a particular ivy settings that includes many resolvers ...
>
> then each module calls ivy:configure pointing to an ivy settings that just points to the locally built repo.
>
> the problem is that since this is all happening from within a single "ant" call, the ivy settings, and the resolvers set up when the top level build call the dependencies module are still in effect when the other modules are built, even though ivy:configure was called again w/ the simpler set of resolvers. the results is that i see errors like :
>
> [ivy:retrieve] :: problems summary ::
> [ivy:retrieve] :::: ERRORS
> [ivy:retrieve]  unknown resolver ibiblio-maven2
> [ivy:retrieve]  unknown resolver ibiblio-maven2
> ...
>
> the build still succeeds, but i'd sure like to make those errors go away.
>
> the root problem i guess is that i want to re-configure ivy from within a single ant call. is this possible?

Two things here:
- if you call your dependencies and other builds from the same ant
build (top level), there is no way with current Ivy version to
reconfigure Ivy... except by using a version with the patch provided
by Gilles (see https://issues.apache.org/jira/browse/IVY-366). This
issue should be fixed by 2.0 release, and even certinaly in next alpha
or beta version.
- the current cache implementation of Ivy stores which resolver found
the module and output the warning you see if it doesn't find the
resolver which found the module first. But this will certainly be
addressed by IVY-399 (for which there is no due date but a strong push
from the community, vote for it to make us even strongly consider it
:-))

Xavier

>
>
>
>
> ---------------------------------
> Ahhh...imagining that irresistible "new car" smell?
>  Check outnew cars at Yahoo! Autos.


-- 
Learn Ivy at ApacheCon: http://www.eu.apachecon.com/
Manage your dependencies with Ivy!
http://incubator.apache.org/ivy/


 
---------------------------------
Finding fabulous fares is fun.
Let Yahoo! FareChase search your favorite travel sites to find flight and hotel bargains.

Re: resetting resolvers / re-configuring ivy

Posted by Xavier Hanin <xa...@gmail.com>.
On 5/2/07, jeff <je...@yahoo.com> wrote:
> i have a multi-level project. there is a top level build.xml that essentially sets up dependencies for and calls module build.xml's ...
>
> one of the modules is "dependencies", and it's job is to simply create a local file system repo for the rest of the modules to use.
>
> the problem is that when the top level build.xml calls dependencies, that module calls ivy:configure with a particular ivy settings that includes many resolvers ...
>
> then each module calls ivy:configure pointing to an ivy settings that just points to the locally built repo.
>
> the problem is that since this is all happening from within a single "ant" call, the ivy settings, and the resolvers set up when the top level build call the dependencies module are still in effect when the other modules are built, even though ivy:configure was called again w/ the simpler set of resolvers. the results is that i see errors like :
>
> [ivy:retrieve] :: problems summary ::
> [ivy:retrieve] :::: ERRORS
> [ivy:retrieve]  unknown resolver ibiblio-maven2
> [ivy:retrieve]  unknown resolver ibiblio-maven2
> ...
>
> the build still succeeds, but i'd sure like to make those errors go away.
>
> the root problem i guess is that i want to re-configure ivy from within a single ant call. is this possible?

Two things here:
- if you call your dependencies and other builds from the same ant
build (top level), there is no way with current Ivy version to
reconfigure Ivy... except by using a version with the patch provided
by Gilles (see https://issues.apache.org/jira/browse/IVY-366). This
issue should be fixed by 2.0 release, and even certinaly in next alpha
or beta version.
- the current cache implementation of Ivy stores which resolver found
the module and output the warning you see if it doesn't find the
resolver which found the module first. But this will certainly be
addressed by IVY-399 (for which there is no due date but a strong push
from the community, vote for it to make us even strongly consider it
:-))

Xavier

>
>
>
>
> ---------------------------------
> Ahhh...imagining that irresistible "new car" smell?
>  Check outnew cars at Yahoo! Autos.


-- 
Learn Ivy at ApacheCon: http://www.eu.apachecon.com/
Manage your dependencies with Ivy!
http://incubator.apache.org/ivy/