Class TestManageTableErasureCodingPolicy
java.lang.Object
org.apache.hadoop.hbase.master.procedure.TestManageTableErasureCodingPolicy
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static interface -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final HBaseClassTestRuleprivate static final org.apache.hadoop.hbase.TableNameprivate static final org.apache.hadoop.hbase.client.TableDescriptorprivate static booleanprivate static final byte[]private static final org.slf4j.Loggerprivate static final org.apache.hadoop.hbase.TableNameprivate static final org.apache.hadoop.hbase.client.TableDescriptorprivate static final HBaseTestingUtility -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidprivate voidassertPolicyValidationException(String message, String expected) static voidprivate voidcheckPolicy(org.apache.hadoop.hdfs.DistributedFileSystem dfs, org.apache.hadoop.fs.Path path, String expectedPolicy) private voidcheckRegionDirAndFilePolicies(org.apache.hadoop.hdfs.DistributedFileSystem dfs, org.apache.hadoop.fs.Path rootDir, org.apache.hadoop.hbase.TableName testTable, String expectedDirPolicy, String expectedFilePolicy) private voidcompactAwayOldFiles(org.apache.hadoop.hbase.TableName tableName) private static booleanenableErasureCoding(org.apache.hadoop.hdfs.DistributedFileSystem fs) voidvoidprivate voidrecreateTable(org.apache.hadoop.hbase.client.Admin admin, org.apache.hadoop.hbase.client.TableDescriptor desc) private voidrunValidatePolicyNameTest(Function<org.apache.hadoop.hbase.client.Admin, org.apache.hadoop.hbase.client.TableDescriptor> descriptorSupplier, TestManageTableErasureCodingPolicy.ThrowingTableDescriptorConsumer consumer) voidvoidvoid
-
Field Details
-
CLASS_RULE
-
LOG
-
UTIL
-
FAMILY
-
NON_EC_TABLE
-
NON_EC_TABLE_DESC
-
EC_TABLE
-
EC_TABLE_DESC
-
erasureCodingSupported
-
-
Constructor Details
-
TestManageTableErasureCodingPolicy
public TestManageTableErasureCodingPolicy()
-
-
Method Details
-
beforeClass
- Throws:
Exception
-
enableErasureCoding
private static boolean enableErasureCoding(org.apache.hadoop.hdfs.DistributedFileSystem fs) throws IOException - Throws:
IOException
-
afterClass
- Throws:
Exception
-
itValidatesPolicyNameForCreate
-
itValidatesPolicyNameForAlter
-
runValidatePolicyNameTest
private void runValidatePolicyNameTest(Function<org.apache.hadoop.hbase.client.Admin, org.apache.hadoop.hbase.client.TableDescriptor> descriptorSupplier, TestManageTableErasureCodingPolicy.ThrowingTableDescriptorConsumer consumer) -
assertPolicyValidationException
-
testCreateTableErasureCodingSync
- Throws:
IOException
-
recreateTable
private void recreateTable(org.apache.hadoop.hbase.client.Admin admin, org.apache.hadoop.hbase.client.TableDescriptor desc) throws IOException - Throws:
IOException
-
testModifyTableErasureCodingSync
- Throws:
IOException
-
compactAwayOldFiles
- Throws:
IOException
-
testRestoreSnapshot
- Throws:
IOException
-
checkRegionDirAndFilePolicies
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 - Throws:
IOException
-
checkPolicy
private void checkPolicy(org.apache.hadoop.hdfs.DistributedFileSystem dfs, org.apache.hadoop.fs.Path path, String expectedPolicy) throws IOException - Throws:
IOException
-