> -----Original Message----- > From: Daniel Dekany [mailto:[email protected]] > Sent: Thursday, March 12, 2009 10:40 AM > To: Brown, Carlton > Subject: Re: [solved] How to prevent "unknown resolver" errors? > [snip] > >> > >> To answer my above question... I now tried using separate > >> *resolution* caches for each ivysetting.xml-s, but with the common > >> per-user > >> *repository* cache, ${user.home}/.ivy2/cache. As the > >> ivysetting.xml-specific resolver names still get into > >> ${user.home}/.ivy2/cache (yes, into the *repository* cache part of > >> it), it can still cause "undefined resolver" errors in *other* > >> projects that use ${user.home}/.ivy2/cache too. It doesn't cause > >> errors in my project though, as it knows the custom resolvers. > > > > If you're getting this behavior, think you've either made > an error in > > configuration or uncovered a bug. Could you post your respective > > config files rather than describing what you did? > > I would believe that the authors are aware of this. Simply, > the name of the last resolver of an artifact is stored in the > ivydata-[revision].properties file as the "resolver" > property. And that file belongs to the repository cache, not > to the resolution cache, right?
Correct, it was my mistake. The repository cache does contain resolver information (at least as of 2.0.0). I think the design is sound... The cache should contain some resolver state, otherwise it couldn't work offline and still respect the resolvers that Ivy does know about. But I think the "unknown resolver" error is a bug... in my opinion Ivy shouldn't error out if it encounters an unknown resolver, as long as the resolver doesn't get used. You can go here and open a bug and see if the developers agree: https://issues.apache.org/jira/browse/IVY [snip] > Simply, since multiple projects use the same ivysettings.xml, > and they may be built in parallel (think about a continuos > integration server), and the resolution caches shouldn't be > accessed concurrently (according to the Ivy docs), I think I > can't use just one resolution cache per ivysettings.xml. Can > I? You can specify the default cache as a property and then override it from the build script before you call ivy:settings. ----------------------------------------- ==================================================== This message contains PRIVILEGED and CONFIDENTIAL information that is intended only for use by the named recipient. If you are not the named recipient, any disclosure, dissemination, or action based on the contents of this message is prohibited. In such case please notify us and destroy and delete all copies of this transmission. Thank you. ====================================================
