From 05712301fc723113436c12d59aafeda4097105a3 Mon Sep 17 00:00:00 2001 From: Maarten Coene Date: Fri, 23 Oct 2009 18:42:40 +0000 Subject: [PATCH] FIX: ChainResolver doesn't pass the specified 'checkmodified' attribute to the cache (IVY-1133) git-svn-id: https://svn.apache.org/repos/asf/ant/ivy/core/trunk@829170 13f79535-47bb-0310-9956-ffa450edef68 --- CHANGES.txt | 1 + .../ivy/plugins/resolver/ChainResolver.java | 28 +------------------ 2 files changed, 2 insertions(+), 27 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index 6ac64f9e..5626257b 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -96,6 +96,7 @@ for detailed view of each issue, please consult http://issues.apache.org/jira/br ===================================== - IMPROVEMENT: use defaultconf in combination with defaultconfmapping (IVY-1135) (thanks to Jon Schneider) +- FIX: ChainResolver doesn't pass the specified 'checkmodified' attribute to the cache (IVY-1133) - FIX: Ivy couldn't handle maven POMs that depend on theirselves - FIX: SearchEngine.listModules returns MRID without extra attributes (IVY-1128) (thanks to Michael Scheetz) - FIX: IvyBuildNumber non-deterministic behaviour (IVY-1120) diff --git a/src/java/org/apache/ivy/plugins/resolver/ChainResolver.java b/src/java/org/apache/ivy/plugins/resolver/ChainResolver.java index 1f83aaa0..b31588b9 100644 --- a/src/java/org/apache/ivy/plugins/resolver/ChainResolver.java +++ b/src/java/org/apache/ivy/plugins/resolver/ChainResolver.java @@ -73,34 +73,10 @@ public class ChainResolver extends AbstractResolver { private boolean dual; - private Boolean checkmodified = null; - public void add(DependencyResolver resolver) { chain.add(resolver); } - /** - * True if this resolver should check lastmodified date to know if ivy files are up to date. - * - * @return - */ - public boolean isCheckmodified() { - if (checkmodified == null) { - if (getSettings() != null) { - String check = getSettings().getVariable("ivy.resolver.default.check.modified"); - return check != null ? Boolean.valueOf(check).booleanValue() : false; - } else { - return false; - } - } else { - return checkmodified.booleanValue(); - } - } - - public void setCheckmodified(boolean check) { - checkmodified = Boolean.valueOf(check); - } - public ResolvedModuleRevision getDependency(DependencyDescriptor dd, ResolveData data) throws ParseException { data = new ResolveData(data, doValidate(data)); @@ -115,9 +91,7 @@ public class ChainResolver extends AbstractResolver { mr = findModuleInCache(dd, data, true); if (mr != null) { Message.verbose(getName() + ": module revision found in cache: " + mr.getId()); - if (!isCheckmodified()) { - mr = forcedRevision(mr); - } + mr = forcedRevision(mr); } }