let's have modules A, B and C. A depends on B which depends on C.
I have following versions released :
- A - none, depends on B : 0.0.+
- B - 0.0.1 , depends on C : 0.0.+, released with C rev=0.0.1,
- C - 0.0.1 and 0.0.2
In order to always use freshest released version matching constraints I tried to use resolveMode="dynamic" in resolve task. This worked for resolve (report shows correct dependency choosen (C:0.0.2). However retrieve happily ignores it and downloads 0.0.1. I'm resolving with resolveId and retrieving with the same resolveId.
I tracked this a little bit.
Inside IvyPostResolveTask there is prepareAndCheck method. It does some magic which gets down to that ivy in most scenarios (when retrieval is not inline for known module and organisation) does a second resolve inside retrieve to get configurations for retrieval. This is done in ensureResolve method:
First - could someone please rationalise this resolve inside retrieve ?
Second - this resolve happily ignores whatever resolveMode I did set previously.
The workaround I did was to extend IvyPostResolveTask with resolveMode parameter and put it explicitly in to the ant config, but maybe there is a better solution ?
If the above is accepted I can produce a patch against trunk and post it here.
|Field||Original Value||New Value|
|Summary||Retrieve ant task doesn't respect dynamic revisions for transient dependencies||Retrieve ant task doesn't respect dynamic revisions for transitive dependencies|
|Summary||Retrieve ant task doesn't respect dynamic revisions for transitive dependencies||Retrieve ant task doesn't support dynamic resolve mode|
|Issue Type||Bug [ 1 ]||Improvement [ 4 ]|
|Assignee||Maarten Coene [ maartenc ]|
|Fix Version/s||2.1.0-RC2 [ 12314062 ]|
|Affects Version/s||2.1.0 [ 12313842 ]|
|Status||Open [ 1 ]||Resolved [ 5 ]|
|Resolution||Fixed [ 1 ]|
|Transition||Time In Source Status||Execution Times||Last Executer||Last Execution Date|
|35d 2h 25m||1||Maarten Coene||01/Jul/09 23:01|