Duo Zhang created HBASE-27269:
---------------------------------

             Summary: The implementation of 
TestReplicationStatus.waitOnMetricsReport is incorrect
                 Key: HBASE-27269
                 URL: https://issues.apache.org/jira/browse/HBASE-27269
             Project: HBase
          Issue Type: Bug
          Components: Replication, test
            Reporter: Duo Zhang


{code}
  private List<ReplicationLoadSource> waitOnMetricsReport(int greaterThan, 
ServerName serverName)
    throws IOException {
    ClusterMetrics metrics = 
hbaseAdmin.getClusterMetrics(EnumSet.of(Option.LIVE_SERVERS));
    List<ReplicationLoadSource> list =
      
metrics.getLiveServerMetrics().get(serverName).getReplicationLoadSourceList();
    while (list.size() <= greaterThan) {
      Threads.sleep(1000);
    }
    return list;
  }
{code}

Obviously the while loop is just a dummy one as the list will not be updated in 
the loop...



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to