[ 
https://issues.apache.org/jira/browse/IVY-1049?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12774814#action_12774814
 ] 

Jeffrey Sinclair commented on IVY-1049:
---------------------------------------

Eric, to comment on your question: 'What does it matter which resolver actually 
was used to populate the cache?'... 

Having the cache segregated by resolver is important when you have multiple 
repositories with the same module naming convention. In the environment I work 
in we have two repositories: one for production and one for development. We 
keep the organisation/module/revision the same across the repositories to make 
it very easy to switch between them: i.e. you simply use a different resolver. 
Perhaps branches could be used, however we liked the idea that you can look at 
an ivysettings.xml file or ivy report and clearly see what development 
dependencies you have, reducing the chance that someone might try to go into 
production with them.

Similarly a shared cache which is used to resolve 'shadow' dependencies in 
development needs cache segregation by resolver in order to avoid different 
shadows trampling over the other's meta data. If Ivy did not store which 
resolver was used to populate different artifacts in the cache, it would not be 
able to handle this use-case.

With the exception of aggregate resolvers (such as the chain resolver), I would 
recommend setting a cache per resolver to avoid any issues with the above 
scenarios.


> Describe how to setup the caches, especailly for multiple ivysettings.xml-s
> ---------------------------------------------------------------------------
>
>                 Key: IVY-1049
>                 URL: https://issues.apache.org/jira/browse/IVY-1049
>             Project: Ivy
>          Issue Type: Improvement
>          Components: Documentation
>    Affects Versions: 2.0
>            Reporter: Daniel Dekany
>
> When using more the one ivysettings.xml-s inside the same user account (same 
> computer), the result is often a lot of "unknown resolver" errors, and other 
> such mess. The cause is that caches were not set up properly: I guess usually 
> there should be one repository cache per ivysettings.xml, then one dedicated 
> resolution cache per ivysettings.xml too (at least, because if parallel 
> builds use a common ivysettings.xml, then each of them needs its own). These 
> I mostly deduced from mailing list discussions and experimenting, not from 
> the documentation. So, these things should be well described, and then linked 
> from every place that's about wiring ivysettings.xml-s. (Even maybe the 
> "unknown resolver" error messages could contain a hint about what the problem 
> could be.) Also, the users should be warned about the importance of lock 
> strategies. (I know that in principle these could be find out from 
> http://ant.apache.org/ivy/history/latest-release/concept.html#cache, but that 
> description is at best sparse, and the implications are not described. Also 
> it's not on a very well visible place.)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to