Class TestWALProcedureStore
java.lang.Object
org.apache.hadoop.hbase.procedure2.store.wal.TestWALProcedureStore
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final HBaseClassTestRule
private org.apache.hadoop.fs.FileSystem
private final HBaseCommonTestingUtility
private static final org.slf4j.Logger
private org.apache.hadoop.fs.Path
private static final int
private org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore
private org.apache.hadoop.fs.Path
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprivate 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) 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
void
void
void
void
void
void
void
void
void
testLoad()
void
void
void
void
void
void
void
void
void
void
void
void
void
Tests that tracker for all old logs are loaded back after procedure store is restarted.private void
verifyProcIdsOnRestart
(Set<Long> procIds)
-
Field Details
-
CLASS_RULE
-
LOG
-
PROCEDURE_STORE_SLOTS
- See Also:
-
procStore
-
htu
-
fs
-
testDir
-
logDir
-
-
Constructor Details
-
TestWALProcedureStore
public TestWALProcedureStore()
-
-
Method Details
-
setupConfig
-
setUp
- Throws:
IOException
-
tearDown
- Throws:
IOException
-
storeRestart
private void storeRestart(org.apache.hadoop.hbase.procedure2.store.ProcedureStore.ProcedureLoader loader) throws Exception - Throws:
Exception
-
testEmptyRoll
- Throws:
Exception
-
testRestartWithoutData
- Throws:
Exception
-
trackersLoadedForAllOldLogs
Tests that tracker for all old logs are loaded back after procedure store is restarted.- Throws:
Exception
-
testWalCleanerSequentialClean
- Throws:
Exception
-
testWalCleanerNoHoles
- Throws:
Exception
-
testWalCleanerUpdates
- Throws:
Exception
-
testWalCleanerUpdatesDontLeaveHoles
- Throws:
Exception
-
testWalCleanerWithEmptyRolls
- Throws:
Exception
-
testEmptyLogLoad
- Throws:
Exception
-
testLoad
- Throws:
Exception
-
testNoTrailerDoubleRestart
- Throws:
Exception
-
testProcIdHoles
- Throws:
Exception
-
testCorruptedTrailer
- Throws:
Exception
-
assertUpdated
private static void assertUpdated(org.apache.hadoop.hbase.procedure2.store.wal.ProcedureStoreTracker tracker, org.apache.hadoop.hbase.procedure2.Procedure<?>[] procs, int[] updatedProcs, int[] nonUpdatedProcs) -
assertDeleted
private static void assertDeleted(org.apache.hadoop.hbase.procedure2.store.wal.ProcedureStoreTracker tracker, org.apache.hadoop.hbase.procedure2.Procedure<?>[] procs, int[] deletedProcs, int[] nonDeletedProcs) -
testCorruptedTrailersRebuild
- Throws:
Exception
-
testCorruptedEntries
- Throws:
Exception
-
testCorruptedProcedures
- Throws:
Exception
-
testRollAndRemove
- Throws:
IOException
-
testFileNotFoundDuringLeaseRecovery
- Throws:
IOException
-
testLogFileAlreadyExists
- Throws:
IOException
-
testLoadChildren
- Throws:
Exception
-
testBatchDelete
- Throws:
Exception
-
testBatchInsert
- Throws:
Exception
-
testWALDirAndWALArchiveDir
- Throws:
IOException
-
createWALProcedureStore
private org.apache.hadoop.hbase.procedure2.store.wal.WALProcedureStore createWALProcedureStore(org.apache.hadoop.conf.Configuration conf) throws IOException - Throws:
IOException
-
restartAndAssert
private ProcedureTestingUtility.LoadCounter restartAndAssert(long maxProcId, long runnableCount, int completedCount, int corruptedCount) throws Exception - Throws:
Exception
-
corruptLog
- Throws:
IOException
-
verifyProcIdsOnRestart
- Throws:
Exception
-