hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ser...@apache.org
Subject svn commit: r1501621 - in /hbase/trunk/hbase-server/src: main/java/org/apache/hadoop/hbase/regionserver/compactions/ test/java/org/apache/hadoop/hbase/regionserver/compactions/
Date Wed, 10 Jul 2013 00:30:10 GMT
Author: sershe
Date: Wed Jul 10 00:30:10 2013
New Revision: 1501621

URL: http://svn.apache.org/r1501621
Log:
HBASE-8329 Limit compaction speed (binlijin) REVERT

Removed:
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/PeakCompactionsThrottle.java
    hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/compactions/TestPeakCompactionsThrottle.java
Modified:
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/OffPeakHours.java

Modified: hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java?rev=1501621&r1=1501620&r2=1501621&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
(original)
+++ hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java
Wed Jul 10 00:30:10 2013
@@ -58,7 +58,6 @@ public abstract class Compactor {
 
   private int compactionKVMax;
   protected Compression.Algorithm compactionCompression;
-  private PeakCompactionsThrottle peakCompactionsThrottle;
 
   //TODO: depending on Store is not good but, realistically, all compactors currently do.
   Compactor(final Configuration conf, final Store store) {
@@ -67,7 +66,6 @@ public abstract class Compactor {
     this.compactionKVMax = this.conf.getInt(HConstants.COMPACTION_KV_MAX, 10);
     this.compactionCompression = (this.store.getFamily() == null) ?
         Compression.Algorithm.NONE : this.store.getFamily().getCompactionCompression();
-    this.peakCompactionsThrottle = new PeakCompactionsThrottle(conf);
   }
 
   /**
@@ -203,7 +201,6 @@ public abstract class Compactor {
     // Limit to "hbase.hstore.compaction.kv.max" (default 10) to avoid OOME
     int closeCheckInterval = HStore.getCloseCheckInterval();
     boolean hasMore;
-    peakCompactionsThrottle.startCompaction();
     do {
       hasMore = scanner.next(kvs, compactionKVMax);
       // output to writer:
@@ -225,12 +222,9 @@ public abstract class Compactor {
             }
           }
         }
-        peakCompactionsThrottle.throttle(kv.getLength());
       }
       kvs.clear();
     } while (hasMore);
-    peakCompactionsThrottle.finishCompaction(this.store.getRegionInfo()
-        .getRegionNameAsString(), this.store.getFamily().getNameAsString());
     progress.complete();
     return true;
   }

Modified: hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/OffPeakHours.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/OffPeakHours.java?rev=1501621&r1=1501620&r2=1501621&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/OffPeakHours.java
(original)
+++ hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/OffPeakHours.java
Wed Jul 10 00:30:10 2013
@@ -37,13 +37,6 @@ public abstract class OffPeakHours {
     return getInstance(startHour, endHour);
   }
 
-  public static OffPeakHours getInstance(Configuration conf, String start,
-      String end) {
-    int startHour = conf.getInt(start, -1);
-    int endHour = conf.getInt(end, -1);
-    return getInstance(startHour, endHour);
-  }
-
   /**
    * @param startHour inclusive
    * @param endHour exclusive



Mime
View raw message