hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t...@apache.org
Subject svn commit: r1068140 - in /hbase/trunk: CHANGES.txt src/main/java/org/apache/hadoop/hbase/io/hfile/LruBlockCache.java
Date Mon, 07 Feb 2011 21:14:55 GMT
Author: todd
Date: Mon Feb  7 21:14:54 2011
New Revision: 1068140

URL: http://svn.apache.org/viewvc?rev=1068140&view=rev
Log:
HBASE-3508. LruBlockCache statistics thread should have a name

Modified:
    hbase/trunk/CHANGES.txt
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/io/hfile/LruBlockCache.java

Modified: hbase/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hbase/trunk/CHANGES.txt?rev=1068140&r1=1068139&r2=1068140&view=diff
==============================================================================
--- hbase/trunk/CHANGES.txt (original)
+++ hbase/trunk/CHANGES.txt Mon Feb  7 21:14:54 2011
@@ -93,6 +93,7 @@ Release 0.90.1 - Unreleased
 
   IMPROVEMENTS
    HBASE-3470  Check that hbase-default.xml is loaded from within jar
+   HBASE-3508  LruBlockCache statistics thread should have a name
 
 Release 0.90.0 - January 19th, 2011
   INCOMPATIBLE CHANGES

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/io/hfile/LruBlockCache.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/io/hfile/LruBlockCache.java?rev=1068140&r1=1068139&r2=1068140&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/io/hfile/LruBlockCache.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/io/hfile/LruBlockCache.java Mon Feb
 7 21:14:54 2011
@@ -37,6 +37,8 @@ import org.apache.hadoop.hbase.util.Byte
 import org.apache.hadoop.hbase.util.ClassSize;
 import org.apache.hadoop.util.StringUtils;
 
+import com.google.common.util.concurrent.ThreadFactoryBuilder;
+
 /**
  * A block cache implementation that is memory-aware using {@link HeapSize},
  * memory-bound using an LRU eviction algorithm, and concurrent: backed by a
@@ -111,7 +113,10 @@ public class LruBlockCache implements Bl
 
   /** Statistics thread schedule pool (for heavy debugging, could remove) */
   private final ScheduledExecutorService scheduleThreadPool =
-    Executors.newScheduledThreadPool(1);
+    Executors.newScheduledThreadPool(1,
+      new ThreadFactoryBuilder()
+        .setNameFormat("LRU Statistics #%d")
+        .build());
 
   /** Current size of cache */
   private final AtomicLong size;



Mime
View raw message