public class TestWALProcedureStore extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
TestWALProcedureStore.TestSequentialProcedure |
| Modifier and Type | Field and Description |
|---|---|
static HBaseClassTestRule |
CLASS_RULE |
private org.apache.hadoop.fs.FileSystem |
fs |
private HBaseCommonTestingUtility |
htu |
private static org.slf4j.Logger |
LOG |
private org.apache.hadoop.fs.Path |
logDir |
private static int |
PROCEDURE_STORE_SLOTS |
private org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore |
procStore |
private org.apache.hadoop.fs.Path |
testDir |
| Constructor and Description |
|---|
TestWALProcedureStore() |
| Modifier and Type | Method and Description |
|---|---|
private static void |
assertDeleted(org.apache.hadoop.hbase.procedure2.store.wal.ProcedureStoreTracker tracker,
org.apache.hadoop.hbase.procedure2.Procedure<?>[] procs,
int[] deletedProcs,
int[] nonDeletedProcs) |
private static void |
assertUpdated(org.apache.hadoop.hbase.procedure2.store.wal.ProcedureStoreTracker tracker,
org.apache.hadoop.hbase.procedure2.Procedure<?>[] procs,
int[] updatedProcs,
int[] nonUpdatedProcs) |
private void |
corruptLog(org.apache.hadoop.fs.FileStatus logFile,
long dropBytes) |
private org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore |
createWALProcedureStore(org.apache.hadoop.conf.Configuration conf) |
private ProcedureTestingUtility.LoadCounter |
restartAndAssert(long maxProcId,
long runnableCount,
int completedCount,
int corruptedCount) |
void |
setUp() |
private void |
setupConfig(org.apache.hadoop.conf.Configuration conf) |
private void |
storeRestart(org.apache.hadoop.hbase.procedure2.store.ProcedureStore.ProcedureLoader loader) |
void |
tearDown() |
void |
testBatchDelete() |
void |
testBatchInsert() |
void |
testCorruptedEntries() |
void |
testCorruptedProcedures() |
void |
testCorruptedTrailer() |
void |
testCorruptedTrailersRebuild() |
void |
testEmptyLogLoad() |
void |
testEmptyRoll() |
void |
testFileNotFoundDuringLeaseRecovery() |
void |
testLoad() |
void |
testLoadChildren() |
void |
testLogFileAlreadyExists() |
void |
testNoTrailerDoubleRestart() |
void |
testProcIdHoles() |
void |
testRestartWithoutData() |
void |
testRollAndRemove() |
void |
testWalCleanerNoHoles() |
void |
testWalCleanerSequentialClean() |
void |
testWalCleanerUpdates() |
void |
testWalCleanerUpdatesDontLeaveHoles() |
void |
testWalCleanerWithEmptyRolls() |
void |
testWALDirAndWALArchiveDir() |
void |
trackersLoadedForAllOldLogs()
Tests that tracker for all old logs are loaded back after procedure store is restarted.
|
private void |
verifyProcIdsOnRestart(Set<Long> procIds) |
public static final HBaseClassTestRule CLASS_RULE
private static final org.slf4j.Logger LOG
private static final int PROCEDURE_STORE_SLOTS
private org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore procStore
private HBaseCommonTestingUtility htu
private org.apache.hadoop.fs.FileSystem fs
private org.apache.hadoop.fs.Path testDir
private org.apache.hadoop.fs.Path logDir
public TestWALProcedureStore()
private void setupConfig(org.apache.hadoop.conf.Configuration conf)
public void setUp() throws IOException
IOExceptionpublic void tearDown() throws IOException
IOExceptionprivate void storeRestart(org.apache.hadoop.hbase.procedure2.store.ProcedureStore.ProcedureLoader loader) throws Exception
Exceptionpublic void testEmptyRoll() throws Exception
Exceptionpublic void testRestartWithoutData() throws Exception
Exceptionpublic void trackersLoadedForAllOldLogs() throws Exception
Exceptionpublic void testWalCleanerSequentialClean() throws Exception
Exceptionpublic void testWalCleanerNoHoles() throws Exception
Exceptionpublic void testWalCleanerUpdates() throws Exception
Exceptionpublic void testWalCleanerUpdatesDontLeaveHoles() throws Exception
Exceptionpublic void testWalCleanerWithEmptyRolls() throws Exception
Exceptionpublic void testEmptyLogLoad() throws Exception
Exceptionpublic void testNoTrailerDoubleRestart() throws Exception
Exceptionpublic void testProcIdHoles() throws Exception
Exceptionpublic void testCorruptedTrailer() throws Exception
Exceptionprivate static void assertUpdated(org.apache.hadoop.hbase.procedure2.store.wal.ProcedureStoreTracker tracker, org.apache.hadoop.hbase.procedure2.Procedure<?>[] procs, int[] updatedProcs, int[] nonUpdatedProcs)
private static void assertDeleted(org.apache.hadoop.hbase.procedure2.store.wal.ProcedureStoreTracker tracker, org.apache.hadoop.hbase.procedure2.Procedure<?>[] procs, int[] deletedProcs, int[] nonDeletedProcs)
public void testCorruptedTrailersRebuild() throws Exception
Exceptionpublic void testCorruptedEntries() throws Exception
Exceptionpublic void testCorruptedProcedures() throws Exception
Exceptionpublic void testRollAndRemove() throws IOException
IOExceptionpublic void testFileNotFoundDuringLeaseRecovery() throws IOException
IOExceptionpublic void testLogFileAlreadyExists() throws IOException
IOExceptionpublic void testLoadChildren() throws Exception
Exceptionpublic void testBatchDelete() throws Exception
Exceptionpublic void testBatchInsert() throws Exception
Exceptionpublic void testWALDirAndWALArchiveDir() throws IOException
IOExceptionprivate org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore createWALProcedureStore(org.apache.hadoop.conf.Configuration conf) throws IOException
IOExceptionprivate ProcedureTestingUtility.LoadCounter restartAndAssert(long maxProcId, long runnableCount, int completedCount, int corruptedCount) throws Exception
Exceptionprivate void corruptLog(org.apache.hadoop.fs.FileStatus logFile, long dropBytes) throws IOException
IOExceptionprivate void verifyProcIdsOnRestart(Set<Long> procIds) throws Exception
ExceptionCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.