hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bus...@apache.org
Subject [07/11] hbase git commit: HBASE-18634 HBASE-Fix client.TestClientClusterStatus (Chia-Ping Tsai) This is a revert of a revert; i.e. a reapply just to fix commit message.
Date Tue, 22 Aug 2017 06:13:06 GMT
HBASE-18634 HBASE-Fix client.TestClientClusterStatus (Chia-Ping Tsai)
This is a revert of a revert; i.e. a reapply just to fix commit message.

This reverts commit fbbae8774ca3162245c0d883c9f477f7d92bc8a5.


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

Branch: refs/heads/HBASE-18467
Commit: 078a6be7d0ccd370016ba351090e21ea0e041e86
Parents: fbbae87
Author: Michael Stack <stack@apache.org>
Authored: Mon Aug 21 14:38:58 2017 -0700
Committer: Michael Stack <stack@apache.org>
Committed: Mon Aug 21 14:38:58 2017 -0700

----------------------------------------------------------------------
 .../hadoop/hbase/client/TestClientClusterStatus.java      | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/078a6be7/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientClusterStatus.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientClusterStatus.java
b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientClusterStatus.java
index 49b4ff2..484ee06 100644
--- a/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientClusterStatus.java
+++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestClientClusterStatus.java
@@ -65,7 +65,7 @@ public class TestClientClusterStatus {
     RegionServerThread rst = rsts.get(rsts.size() - 1);
     DEAD = rst.getRegionServer();
     DEAD.stop("Test dead servers status");
-    while (!DEAD.isStopped()) {
+    while (rst.isAlive()) {
       Thread.sleep(500);
     }
   }
@@ -155,9 +155,11 @@ public class TestClientClusterStatus {
     Assert.assertNotNull(status);
     Assert.assertNotNull(status.getServers());
     // exclude a dead region server
-    Assert.assertEquals(SLAVES, numRs);
-    // live servers = primary master + nums of regionservers
-    Assert.assertEquals(status.getServers().size() + 1 /*Master*/, numRs);
+    Assert.assertEquals(SLAVES -1, numRs);
+    // live servers = nums of regionservers
+    // By default, HMaster don't carry any regions so it won't report its load.
+    // Hence, it won't be in the server list.
+    Assert.assertEquals(status.getServers().size(), numRs);
     Assert.assertTrue(status.getRegionsCount() > 0);
     Assert.assertNotNull(status.getDeadServerNames());
     Assert.assertEquals(1, status.getDeadServersSize());


Mime
View raw message