You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by ra...@apache.org on 2017/09/28 05:07:55 UTC

hbase git commit: HBASE-18888 StealJobQueue should call super() to init the PriorityBlockingQueue (Ram)

Repository: hbase
Updated Branches:
  refs/heads/master 2bf5bbd0a -> 0cf15fadd


HBASE-18888 StealJobQueue should call super() to init the
PriorityBlockingQueue (Ram)


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/0cf15fad
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/0cf15fad
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/0cf15fad

Branch: refs/heads/master
Commit: 0cf15fadd8be8ee9ddb1ef65464bba9b98807b7e
Parents: 2bf5bbd
Author: Ramkrishna <ra...@intel.com>
Authored: Thu Sep 28 10:37:23 2017 +0530
Committer: Ramkrishna <ra...@intel.com>
Committed: Thu Sep 28 10:37:23 2017 +0530

----------------------------------------------------------------------
 .../org/apache/hadoop/hbase/util/StealJobQueue.java | 16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/0cf15fad/hbase-server/src/main/java/org/apache/hadoop/hbase/util/StealJobQueue.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/util/StealJobQueue.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/util/StealJobQueue.java
index 9a5d595..efd3da3 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/util/StealJobQueue.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/util/StealJobQueue.java
@@ -50,21 +50,7 @@ public class StealJobQueue<T> extends PriorityBlockingQueue<T> {
   private final transient Condition notEmpty = lock.newCondition();
 
   public StealJobQueue(Comparator<? super T> comparator) {
-    this.stealFromQueue = new PriorityBlockingQueue<T>(11, comparator) {
-
-      private static final long serialVersionUID = -7070010365201826904L;
-
-      @Override
-      public boolean offer(T t) {
-        lock.lock();
-        try {
-          notEmpty.signal();
-          return super.offer(t);
-        } finally {
-          lock.unlock();
-        }
-      }
-    };
+    this(11, 11, comparator);
   }
 
   public StealJobQueue(int initCapacity, int stealFromQueueInitCapacity,