Class TestReplicationStatus
java.lang.Object
org.apache.hadoop.hbase.replication.TestReplicationBase
org.apache.hadoop.hbase.replication.TestReplicationStatus
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.hadoop.hbase.replication.TestReplicationBase
TestReplicationBase.ReplicationEndpointTest -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final HBaseClassTestRuleprivate static final org.slf4j.LoggerFields inherited from class org.apache.hadoop.hbase.replication.TestReplicationBase
CONF_WITH_LOCALFS, CONF1, CONF2, connection1, connection2, famName, hbaseAdmin, htable1, htable2, NB_RETRIES, NB_ROWS_IN_BATCH, NB_ROWS_IN_BIG_BATCH, noRepfamName, NUM_SLAVES1, NUM_SLAVES2, PEER_ID2, replicateCount, replicatedEntries, row, SLEEP_TIME, tableName, UTIL1, UTIL2 -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static voidvoidTest for HBASE-9531.private List<org.apache.hadoop.hbase.replication.ReplicationLoadSource>waitOnMetricsReport(int greaterThan, org.apache.hadoop.hbase.ServerName serverName) Wait until Master shows metrics counts for ReplicationLoadSourceList that are greater thangreaterThanforserverNamebefore returning.Methods inherited from class org.apache.hadoop.hbase.replication.TestReplicationBase
addPeer, addPeer, cleanUp, configureClusters, createTable, getClusterKey, isSerialPeer, isSyncPeer, loadData, loadData, removePeer, removePeer, restartSourceCluster, restartTargetHBaseCluster, runSimplePutDeleteTest, runSmallBatchTest, setUpBase, setUpBeforeClass, setupConfig, stopAllRegionServers, tearDownAfterClass, tearDownBase, waitForReplication, waitForReplication
-
Field Details
-
LOG
-
CLASS_RULE
-
-
Constructor Details
-
TestReplicationStatus
public TestReplicationStatus()
-
-
Method Details
-
insertRowsOnSource
- Throws:
IOException
-
testReplicationStatus
Test for HBASE-9531. put a few rows into htable1, which should be replicated to htable2
create a ClusterStatus instance 'status' from HBaseAdmin
test : status.getLoad(server).getReplicationLoadSourceList()
test : status.getLoad(server).getReplicationLoadSink()- Throws:
Exception
-
waitOnMetricsReport
private List<org.apache.hadoop.hbase.replication.ReplicationLoadSource> waitOnMetricsReport(int greaterThan, org.apache.hadoop.hbase.ServerName serverName) throws Exception Wait until Master shows metrics counts for ReplicationLoadSourceList that are greater thangreaterThanforserverNamebefore returning. We want to avoid case where RS hasn't yet updated Master before allowing test proceed.- Parameters:
greaterThan- size of replicationLoadSourceList must be greater before we proceed- Throws:
Exception
-