HBASE-5809 Avoid move api to take the destination server same as the source server. Addendum to correct tet case. (Ted)

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1328594 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
ramkrishna 2012-04-21 07:00:46 +00:00
parent 14f80913e5
commit 144b27d1a3
1 changed files with 3 additions and 3 deletions

View File

@ -655,13 +655,13 @@ public class TestMasterObserver {
// Try to force a move
Collection<ServerName> servers = master.getClusterStatus().getServers();
String destName = null;
String firstRegionHostnamePortStr = firstGoodPair.getValue().toString();
LOG.info("firstRegionHostnamePortStr=" + firstRegionHostnamePortStr);
String serverNameForFirstRegion = firstGoodPair.getValue().toString();
LOG.info("serverNameForFirstRegion=" + serverNameForFirstRegion);
boolean found = false;
// Find server that is NOT carrying the first region
for (ServerName info : servers) {
LOG.info("ServerName=" + info);
if (!firstRegionHostnamePortStr.equals(info.getHostAndPort())) {
if (!serverNameForFirstRegion.equals(info.getServerName())) {
destName = info.toString();
found = true;
break;