public class BaseTestHBaseFsck extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
BaseTestHBaseFsck.MasterSyncCoprocessor |
| Modifier and Type | Field and Description |
|---|---|
protected static Admin |
admin |
protected static org.apache.hadoop.hbase.master.assignment.AssignmentManager |
assignmentManager |
protected static org.apache.hadoop.conf.Configuration |
conf |
protected static ClusterConnection |
connection |
protected static byte[] |
FAM |
protected static String |
FAM_STR |
protected static ScheduledThreadPoolExecutor |
hbfsckExecutorService |
protected static org.slf4j.Logger |
LOG |
org.junit.rules.TestName |
name |
protected static int |
REGION_ONLINE_TIMEOUT |
protected static org.apache.hadoop.hbase.master.assignment.RegionStates |
regionStates |
protected static byte[][] |
ROWKEYS |
protected static byte[][] |
SPLITS |
protected static ExecutorService |
tableExecutorService |
protected Table |
tbl |
protected static HBaseTestingUtility |
TEST_UTIL |
| Constructor and Description |
|---|
BaseTestHBaseFsck() |
| Modifier and Type | Method and Description |
|---|---|
static void |
createTable(HBaseTestingUtility testUtil,
HTableDescriptor htd,
byte[][] splitKeys) |
protected void |
deleteMetaRegion(org.apache.hadoop.conf.Configuration conf,
boolean unassign,
boolean hdfs,
boolean regionInfoOnly) |
protected void |
deleteRegion(org.apache.hadoop.conf.Configuration conf,
HTableDescriptor htd,
byte[] startKey,
byte[] endKey,
boolean unassign,
boolean metaRow,
boolean hdfs)
Delete a region from assignments, meta, or completely from hdfs.
|
protected void |
deleteRegion(org.apache.hadoop.conf.Configuration conf,
HTableDescriptor htd,
byte[] startKey,
byte[] endKey,
boolean unassign,
boolean metaRow,
boolean hdfs,
boolean regionInfoOnly,
int replicaId)
Delete a region from assignments, meta, or completely from hdfs.
|
static void |
deleteTable(HBaseTestingUtility testUtil,
TableName tableName) |
void |
deleteTableDir(TableName table) |
protected void |
doQuarantineTest(TableName table,
HBaseFsck hbck,
int check,
int corrupt,
int fail,
int quar,
int missing)
Test that use this should have a timeout, because this method could potentially wait forever.
|
protected void |
dumpMeta(TableName tableName)
Debugging method to dump the contents of meta.
|
protected void |
undeployRegion(Connection conn,
ServerName sn,
RegionInfo hri)
This method is used to undeploy a region -- close it and attempt to
remove its state from the Master.
|
protected static final org.slf4j.Logger LOG
protected static final HBaseTestingUtility TEST_UTIL
protected static final org.apache.hadoop.conf.Configuration conf
protected static final String FAM_STR
protected static final byte[] FAM
protected static final int REGION_ONLINE_TIMEOUT
protected static org.apache.hadoop.hbase.master.assignment.AssignmentManager assignmentManager
protected static org.apache.hadoop.hbase.master.assignment.RegionStates regionStates
protected static ExecutorService tableExecutorService
protected static ScheduledThreadPoolExecutor hbfsckExecutorService
protected static ClusterConnection connection
protected static final byte[][] SPLITS
protected static final byte[][] ROWKEYS
public org.junit.rules.TestName name
public BaseTestHBaseFsck()
protected void dumpMeta(TableName tableName) throws IOException
IOExceptionprotected void undeployRegion(Connection conn, ServerName sn, RegionInfo hri) throws IOException, InterruptedException
IOExceptionInterruptedExceptionprotected void deleteRegion(org.apache.hadoop.conf.Configuration conf, HTableDescriptor htd, byte[] startKey, byte[] endKey, boolean unassign, boolean metaRow, boolean hdfs) throws IOException, InterruptedException
unassign - if true unassign region if assignedmetaRow - if true remove region's row from METAhdfs - if true remove region's dir in HDFSIOExceptionInterruptedExceptionprotected void deleteRegion(org.apache.hadoop.conf.Configuration conf, HTableDescriptor htd, byte[] startKey, byte[] endKey, boolean unassign, boolean metaRow, boolean hdfs, boolean regionInfoOnly, int replicaId) throws IOException, InterruptedException
unassign - if true unassign region if assignedmetaRow - if true remove region's row from METAhdfs - if true remove region's dir in HDFSregionInfoOnly - if true remove a region dir's .regioninfo filereplicaId - replica idIOExceptionInterruptedExceptionpublic void deleteTableDir(TableName table) throws IOException
IOExceptionprotected void doQuarantineTest(TableName table, HBaseFsck hbck, int check, int corrupt, int fail, int quar, int missing) throws Exception
Exceptionprotected void deleteMetaRegion(org.apache.hadoop.conf.Configuration conf, boolean unassign, boolean hdfs, boolean regionInfoOnly) throws IOException, InterruptedException
IOExceptionInterruptedExceptionpublic static void createTable(HBaseTestingUtility testUtil, HTableDescriptor htd, byte[][] splitKeys) throws Exception
Exceptionpublic static void deleteTable(HBaseTestingUtility testUtil, TableName tableName) throws Exception
ExceptionCopyright © 2007–2019 Cloudera. All rights reserved.