hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject svn commit: r1138305 - /hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
Date Wed, 22 Jun 2011 05:27:08 GMT
Author: stack
Date: Wed Jun 22 05:27:08 2011
New Revision: 1138305

URL: http://svn.apache.org/viewvc?rev=1138305&view=rev
Log:
HBASE-3986 troubleshooting.xml - adding client long-pause and NotServingRegionException entries
-- back out mistaken HRS commit

Modified:
    hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java

Modified: hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java
URL: http://svn.apache.org/viewvc/hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java?rev=1138305&r1=1138304&r2=1138305&view=diff
==============================================================================
--- hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java (original)
+++ hbase/trunk/src/main/java/org/apache/hadoop/hbase/regionserver/HRegionServer.java Wed
Jun 22 05:27:08 2011
@@ -1050,22 +1050,12 @@ public class HRegionServer implements HR
    */
   private static class CompactionChecker extends Chore {
     private final HRegionServer instance;
-    private final int majorCompactPriority;
-    private final static int DEFAULT_PRIORITY = -1;
 
     CompactionChecker(final HRegionServer h, final int sleepTime,
         final Stoppable stopper) {
       super("CompactionChecker", sleepTime, h);
       this.instance = h;
       LOG.info("Runs every " + StringUtils.formatTime(sleepTime));
-      
-      /* MajorCompactPriority is configurable.
-       * If not set, it will get the value of hbase.hstore.blockingStoreFiles,
-       * and the compaction will use default priority.
-       */
-      this.majorCompactPriority = this.instance.conf.
-        getInt("hbase.regionserver.compactionChecker.majorCompactPriority",
-        DEFAULT_PRIORITY);      
     }
 
     @Override
@@ -1075,19 +1065,10 @@ public class HRegionServer implements HR
           continue;
         for (Store s : r.getStores().values()) {
           try {
-            if (s.needsCompaction()) {
+            if (s.isMajorCompaction() || s.needsCompaction()) {
               // Queue a compaction. Will recognize if major is needed.
               this.instance.compactSplitThread.requestCompaction(r, s,
-                getName() + " requests compaction");
-            } else if (s.isMajorCompaction()) {
-              if (majorCompactPriority == DEFAULT_PRIORITY ) {
-                this.instance.compactSplitThread.requestCompaction(r, s,
-                    getName() + " requests major compaction; use default priority");	
-              } else {
-            	this.instance.compactSplitThread.requestCompaction(r, s,
-                  getName() + " requests major compaction; use configured priority",
-                  this.majorCompactPriority); 
-              }
+                  getName() + " requests major compaction");
             }
           } catch (IOException e) {
             LOG.warn("Failed major compaction check on " + r, e);



Mime
View raw message