hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From szets...@apache.org
Subject hadoop git commit: In Balancer, the target task should be removed when its size < 0. Contributed by Yiqun Lin
Date Thu, 04 Aug 2016 16:53:29 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2 c7fe1f5ec -> 5004b0571


In Balancer, the target task should be removed when its size < 0.  Contributed by Yiqun
Lin


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/5004b057
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/5004b057
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/5004b057

Branch: refs/heads/branch-2
Commit: 5004b0571e65f16b3913d57abdb63a0b7d8d09fe
Parents: c7fe1f5
Author: Tsz-Wo Nicholas Sze <szetszwo@hortonworks.com>
Authored: Thu Aug 4 09:45:40 2016 -0700
Committer: Tsz-Wo Nicholas Sze <szetszwo@hortonworks.com>
Committed: Thu Aug 4 09:53:15 2016 -0700

----------------------------------------------------------------------
 .../java/org/apache/hadoop/hdfs/server/balancer/Dispatcher.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/5004b057/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/balancer/Dispatcher.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/balancer/Dispatcher.java
b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/balancer/Dispatcher.java
index 8f81c19..9bf549a 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/balancer/Dispatcher.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/balancer/Dispatcher.java
@@ -734,7 +734,7 @@ public class Dispatcher {
             long blockSize = pendingBlock.block.getNumBytes();
             incScheduledSize(-blockSize);
             task.size -= blockSize;
-            if (task.size == 0) {
+            if (task.size <= 0) {
               i.remove();
             }
             return pendingBlock;


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message