public class TestReplicationBase extends Object
Modifier and Type | Class and Description |
---|---|
static class |
TestReplicationBase.ReplicationEndpointTest
Custom replication endpoint to keep track of replication status for tests.
|
Modifier and Type | Field and Description |
---|---|
protected static org.apache.hadoop.hbase.client.replication.ReplicationAdmin |
admin |
protected static org.apache.hadoop.conf.Configuration |
CONF_WITH_LOCALFS |
protected static org.apache.hadoop.conf.Configuration |
CONF1 |
protected static org.apache.hadoop.conf.Configuration |
CONF2 |
protected static org.apache.hadoop.hbase.client.Connection |
connection1 |
protected static org.apache.hadoop.hbase.client.Connection |
connection2 |
protected static byte[] |
famName |
protected static org.apache.hadoop.hbase.client.Admin |
hbaseAdmin |
protected static org.apache.hadoop.hbase.client.Table |
htable1 |
protected static org.apache.hadoop.hbase.client.Table |
htable2 |
private static org.slf4j.Logger |
LOG |
protected static int |
NB_RETRIES |
protected static int |
NB_ROWS_IN_BATCH |
protected static int |
NB_ROWS_IN_BIG_BATCH |
protected static byte[] |
noRepfamName |
protected static int |
NUM_SLAVES1 |
protected static int |
NUM_SLAVES2 |
protected static String |
PEER_ID2 |
protected static AtomicInteger |
replicateCount |
protected static List<org.apache.hadoop.hbase.wal.WAL.Entry> |
replicatedEntries |
protected static byte[] |
row |
protected static long |
SLEEP_TIME |
protected static org.apache.hadoop.hbase.TableName |
tableName |
protected static HBaseTestingUtility |
UTIL1 |
protected static HBaseTestingUtility |
UTIL2 |
Constructor and Description |
---|
TestReplicationBase() |
Modifier and Type | Method and Description |
---|---|
protected void |
addPeer(String peerId,
org.apache.hadoop.hbase.TableName tableName) |
protected void |
cleanUp() |
(package private) static void |
configureClusters(HBaseTestingUtility util1,
HBaseTestingUtility util2) |
protected static void |
createTable(org.apache.hadoop.hbase.TableName tableName) |
protected boolean |
isSerialPeer() |
protected static void |
loadData(String prefix,
byte[] row) |
protected static void |
loadData(String prefix,
byte[] row,
byte[] familyName) |
private boolean |
peerExist(String peerId) |
protected void |
removePeer(String peerId) |
(package private) static void |
restartSourceCluster(int numSlaves) |
(package private) static void |
restartTargetHBaseCluster(int numSlaves) |
protected static void |
runSimplePutDeleteTest() |
protected static void |
runSmallBatchTest() |
void |
setUpBase() |
static void |
setUpBeforeClass() |
protected static void |
setupConfig(HBaseTestingUtility util,
String znodeParent) |
private static void |
startClusters() |
static void |
tearDownAfterClass() |
void |
tearDownBase() |
protected static void |
waitForReplication(int expectedRows,
int retries) |
protected static void |
waitForReplication(org.apache.hadoop.hbase.client.Table table,
int expectedRows,
int retries) |
private static final org.slf4j.Logger LOG
protected static org.apache.hadoop.hbase.client.Connection connection1
protected static org.apache.hadoop.hbase.client.Connection connection2
protected static org.apache.hadoop.conf.Configuration CONF_WITH_LOCALFS
protected static org.apache.hadoop.hbase.client.replication.ReplicationAdmin admin
protected static org.apache.hadoop.hbase.client.Admin hbaseAdmin
protected static org.apache.hadoop.hbase.client.Table htable1
protected static org.apache.hadoop.hbase.client.Table htable2
protected static final HBaseTestingUtility UTIL1
protected static final HBaseTestingUtility UTIL2
protected static org.apache.hadoop.conf.Configuration CONF1
protected static org.apache.hadoop.conf.Configuration CONF2
protected static int NUM_SLAVES1
protected static int NUM_SLAVES2
protected static final int NB_ROWS_IN_BATCH
protected static final int NB_ROWS_IN_BIG_BATCH
protected static final long SLEEP_TIME
protected static final int NB_RETRIES
protected static AtomicInteger replicateCount
protected static volatile List<org.apache.hadoop.hbase.wal.WAL.Entry> replicatedEntries
protected static final org.apache.hadoop.hbase.TableName tableName
protected static final byte[] famName
protected static final byte[] row
protected static final byte[] noRepfamName
protected static final String PEER_ID2
public TestReplicationBase()
protected boolean isSerialPeer()
protected final void cleanUp() throws IOException, InterruptedException
IOException
InterruptedException
protected static void waitForReplication(int expectedRows, int retries) throws IOException, InterruptedException
IOException
InterruptedException
protected static void waitForReplication(org.apache.hadoop.hbase.client.Table table, int expectedRows, int retries) throws IOException, InterruptedException
IOException
InterruptedException
protected static void loadData(String prefix, byte[] row) throws IOException
IOException
protected static void loadData(String prefix, byte[] row, byte[] familyName) throws IOException
IOException
protected static void setupConfig(HBaseTestingUtility util, String znodeParent)
static void configureClusters(HBaseTestingUtility util1, HBaseTestingUtility util2)
static void restartSourceCluster(int numSlaves) throws Exception
Exception
static void restartTargetHBaseCluster(int numSlaves) throws Exception
Exception
protected static void createTable(org.apache.hadoop.hbase.TableName tableName) throws IOException
IOException
private static void startClusters() throws Exception
Exception
public static void setUpBeforeClass() throws Exception
Exception
private boolean peerExist(String peerId) throws IOException
IOException
protected final void addPeer(String peerId, org.apache.hadoop.hbase.TableName tableName) throws Exception
Exception
protected final void removePeer(String peerId) throws Exception
Exception
public void tearDownBase() throws Exception
Exception
protected static void runSimplePutDeleteTest() throws IOException, InterruptedException
IOException
InterruptedException
protected static void runSmallBatchTest() throws IOException, InterruptedException
IOException
InterruptedException
public static void tearDownAfterClass() throws Exception
Exception
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.