public class TestRegionMergeTransactionOnCluster extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
TestRegionMergeTransactionOnCluster.MyMaster |
(package private) static class |
TestRegionMergeTransactionOnCluster.MyMasterRpcServices |
| Modifier and Type | Field and Description |
|---|---|
private static org.apache.hadoop.hbase.client.Admin |
ADMIN |
static HBaseClassTestRule |
CLASS_RULE |
private static byte[] |
FAMILYNAME |
private static int |
INITIAL_REGION_NUM |
private static org.slf4j.Logger |
LOG |
private static org.apache.hadoop.hbase.master.HMaster |
MASTER |
org.junit.rules.TestName |
name |
private static int |
NB_SERVERS |
private static byte[] |
QUALIFIER |
private static byte[] |
ROW |
private static byte[][] |
ROWS |
private static int |
ROWSIZE |
(package private) static HBaseTestingUtility |
TEST_UTIL |
private static int |
waitTime |
| Constructor and Description |
|---|
TestRegionMergeTransactionOnCluster() |
| Modifier and Type | Method and Description |
|---|---|
static void |
afterAllTests() |
static void |
beforeAllTests() |
private org.apache.hadoop.hbase.client.Table |
createTableAndLoadData(org.apache.hadoop.hbase.master.HMaster master,
org.apache.hadoop.hbase.TableName tablename) |
private org.apache.hadoop.hbase.client.Table |
createTableAndLoadData(org.apache.hadoop.hbase.master.HMaster master,
org.apache.hadoop.hbase.TableName tablename,
int numRegions,
int replication) |
private void |
loadData(org.apache.hadoop.hbase.client.Table table) |
private static byte[][] |
makeN(byte[] base,
int n) |
private org.apache.hadoop.hbase.util.PairOfSameType<org.apache.hadoop.hbase.client.RegionInfo> |
mergeRegionsAndVerifyRegionNum(org.apache.hadoop.hbase.master.HMaster master,
org.apache.hadoop.hbase.TableName tablename,
int regionAnum,
int regionBnum,
int expectedRegionNum) |
private org.apache.hadoop.hbase.util.PairOfSameType<org.apache.hadoop.hbase.client.RegionInfo> |
requestMergeRegion(org.apache.hadoop.hbase.master.HMaster master,
org.apache.hadoop.hbase.TableName tablename,
int regionAnum,
int regionBnum) |
void |
testCleanMergeReference() |
void |
testMerge()
This test tests 1, merging region not online;
2, merging same two regions; 3, merging unknown regions.
|
void |
testMergeAndRestartingMaster()
Not really restarting the master.
|
void |
testMergeWithReplicas() |
void |
testWholesomeMerge() |
private void |
verifyRowCount(org.apache.hadoop.hbase.client.Table table,
int expectedRegionNum) |
private void |
waitAndVerifyRegionNum(org.apache.hadoop.hbase.master.HMaster master,
org.apache.hadoop.hbase.TableName tablename,
int expectedRegionNum) |
public static final HBaseClassTestRule CLASS_RULE
private static final org.slf4j.Logger LOG
public org.junit.rules.TestName name
private static final int NB_SERVERS
private static final byte[] FAMILYNAME
private static final byte[] QUALIFIER
private static byte[] ROW
private static final int INITIAL_REGION_NUM
private static final int ROWSIZE
private static byte[][] ROWS
private static int waitTime
static final HBaseTestingUtility TEST_UTIL
private static org.apache.hadoop.hbase.master.HMaster MASTER
private static org.apache.hadoop.hbase.client.Admin ADMIN
public TestRegionMergeTransactionOnCluster()
public static void beforeAllTests() throws Exception
Exceptionpublic static void afterAllTests() throws Exception
Exceptionpublic void testWholesomeMerge() throws Exception
Exceptionpublic void testMergeAndRestartingMaster() throws Exception
Exceptionpublic void testCleanMergeReference() throws Exception
Exceptionpublic void testMerge() throws Exception
Exceptionpublic void testMergeWithReplicas() throws Exception
Exceptionprivate org.apache.hadoop.hbase.util.PairOfSameType<org.apache.hadoop.hbase.client.RegionInfo> mergeRegionsAndVerifyRegionNum(org.apache.hadoop.hbase.master.HMaster master, org.apache.hadoop.hbase.TableName tablename, int regionAnum, int regionBnum, int expectedRegionNum) throws Exception
Exceptionprivate org.apache.hadoop.hbase.util.PairOfSameType<org.apache.hadoop.hbase.client.RegionInfo> requestMergeRegion(org.apache.hadoop.hbase.master.HMaster master, org.apache.hadoop.hbase.TableName tablename, int regionAnum, int regionBnum) throws Exception
Exceptionprivate void waitAndVerifyRegionNum(org.apache.hadoop.hbase.master.HMaster master, org.apache.hadoop.hbase.TableName tablename, int expectedRegionNum) throws Exception
Exceptionprivate org.apache.hadoop.hbase.client.Table createTableAndLoadData(org.apache.hadoop.hbase.master.HMaster master, org.apache.hadoop.hbase.TableName tablename) throws Exception
Exceptionprivate org.apache.hadoop.hbase.client.Table createTableAndLoadData(org.apache.hadoop.hbase.master.HMaster master, org.apache.hadoop.hbase.TableName tablename, int numRegions, int replication) throws Exception
Exceptionprivate static byte[][] makeN(byte[] base, int n)
private void loadData(org.apache.hadoop.hbase.client.Table table) throws IOException
IOExceptionprivate void verifyRowCount(org.apache.hadoop.hbase.client.Table table, int expectedRegionNum) throws IOException
IOExceptionCopyright © 2007–2021 The Apache Software Foundation. All rights reserved.