public class TestManageTableErasureCodingPolicy extends Object
Modifier and Type | Class and Description |
---|---|
(package private) static interface |
TestManageTableErasureCodingPolicy.ThrowingTableDescriptorConsumer |
Modifier and Type | Field and Description |
---|---|
static HBaseClassTestRule |
CLASS_RULE |
private static org.apache.hadoop.hbase.TableName |
EC_TABLE |
private static org.apache.hadoop.hbase.client.TableDescriptor |
EC_TABLE_DESC |
private static byte[] |
FAMILY |
private static org.slf4j.Logger |
LOG |
private static org.apache.hadoop.hbase.TableName |
NON_EC_TABLE |
private static org.apache.hadoop.hbase.client.TableDescriptor |
NON_EC_TABLE_DESC |
private static HBaseTestingUtil |
UTIL |
Constructor and Description |
---|
TestManageTableErasureCodingPolicy() |
Modifier and Type | Method and Description |
---|---|
static void |
afterClass() |
static void |
beforeClass() |
private void |
checkPolicy(org.apache.hadoop.hdfs.DistributedFileSystem dfs,
org.apache.hadoop.fs.Path path,
String expectedPolicy) |
private void |
checkRegionDirAndFilePolicies(org.apache.hadoop.hdfs.DistributedFileSystem dfs,
org.apache.hadoop.fs.Path rootDir,
org.apache.hadoop.hbase.TableName testTable,
String expectedDirPolicy,
String expectedFilePolicy) |
private void |
compactAwayOldFiles(org.apache.hadoop.hbase.TableName tableName) |
void |
itValidatesPolicyNameForAlter() |
void |
itValidatesPolicyNameForCreate() |
private void |
recreateTable(org.apache.hadoop.hbase.client.Admin admin,
org.apache.hadoop.hbase.client.TableDescriptor desc) |
private void |
runValidatePolicyNameTest(Function<org.apache.hadoop.hbase.client.Admin,org.apache.hadoop.hbase.client.TableDescriptor> descriptorSupplier,
TestManageTableErasureCodingPolicy.ThrowingTableDescriptorConsumer consumer) |
void |
testCreateTableErasureCodingSync() |
void |
testModifyTableErasureCodingSync() |
void |
testRestoreSnapshot() |
public static final HBaseClassTestRule CLASS_RULE
private static final org.slf4j.Logger LOG
private static final HBaseTestingUtil UTIL
private static final byte[] FAMILY
private static final org.apache.hadoop.hbase.TableName NON_EC_TABLE
private static final org.apache.hadoop.hbase.client.TableDescriptor NON_EC_TABLE_DESC
private static final org.apache.hadoop.hbase.TableName EC_TABLE
private static final org.apache.hadoop.hbase.client.TableDescriptor EC_TABLE_DESC
public TestManageTableErasureCodingPolicy()
public static void beforeClass() throws Exception
Exception
public static void afterClass() throws Exception
Exception
public void itValidatesPolicyNameForCreate()
public void itValidatesPolicyNameForAlter()
private void runValidatePolicyNameTest(Function<org.apache.hadoop.hbase.client.Admin,org.apache.hadoop.hbase.client.TableDescriptor> descriptorSupplier, TestManageTableErasureCodingPolicy.ThrowingTableDescriptorConsumer consumer)
public void testCreateTableErasureCodingSync() throws IOException
IOException
private void recreateTable(org.apache.hadoop.hbase.client.Admin admin, org.apache.hadoop.hbase.client.TableDescriptor desc) throws IOException
IOException
public void testModifyTableErasureCodingSync() throws IOException, InterruptedException
IOException
InterruptedException
private void compactAwayOldFiles(org.apache.hadoop.hbase.TableName tableName) throws IOException
IOException
public void testRestoreSnapshot() throws IOException
IOException
private void checkRegionDirAndFilePolicies(org.apache.hadoop.hdfs.DistributedFileSystem dfs, org.apache.hadoop.fs.Path rootDir, org.apache.hadoop.hbase.TableName testTable, String expectedDirPolicy, String expectedFilePolicy) throws IOException
IOException
private void checkPolicy(org.apache.hadoop.hdfs.DistributedFileSystem dfs, org.apache.hadoop.fs.Path path, String expectedPolicy) throws IOException
IOException
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.