Selaa lähdekoodia

HADOOP-4650. Correct a mismatch between the default value of
local.cache.size in the config and the source. Contributed by Jeff Hammerbacher.


git-svn-id: https://svn.apache.org/repos/asf/hadoop/core/trunk@713825 13f79535-47bb-0310-9956-ffa450edef68

Christopher Douglas 16 vuotta sitten
vanhempi
commit
3acbfe4ef5
2 muutettua tiedostoa jossa 6 lisäystä ja 2 poistoa
  1. 4 0
      CHANGES.txt
  2. 2 2
      src/core/org/apache/hadoop/filecache/DistributedCache.java

+ 4 - 0
CHANGES.txt

@@ -142,6 +142,10 @@ Trunk (unreleased changes)
     HADOOP-4589. Correct PiEstimator output messages and improve the code
     readability. (szetszwo)
 
+    HADOOP-4650. Correct a mismatch between the default value of
+    local.cache.size in the config and the source. (Jeff Hammerbacher via
+    cdouglas)
+
 Release 0.19.0 - Unreleased
 
   INCOMPATIBLE CHANGES

+ 2 - 2
src/core/org/apache/hadoop/filecache/DistributedCache.java

@@ -117,7 +117,7 @@ public class DistributedCache {
   private static TreeMap<String, CacheStatus> cachedArchives = new TreeMap<String, CacheStatus>();
   
   // default total cache size
-  private static final long DEFAULT_CACHE_SIZE = 1048576L;
+  private static final long DEFAULT_CACHE_SIZE = 10737418240L;
 
   private static final Log LOG =
     LogFactory.getLog(DistributedCache.class);
@@ -208,7 +208,7 @@ public class DistributedCache {
 
     // try deleting stuff if you can
     long size = FileUtil.getDU(new File(baseDir.toString()));
-    // setting the cache size to a default of 1MB
+    // setting the cache size to a default of 10GB
     long allowedSize = conf.getLong("local.cache.size", DEFAULT_CACHE_SIZE);
     if (allowedSize < size) {
       // try some cache deletions