Package org.apache.hadoop.hbase.wal
Class TestWALFactory
java.lang.Object
org.apache.hadoop.hbase.wal.TestWALFactory
WAL tests that can be reused across providers.
-
Nested Class Summary
Modifier and TypeClassDescriptionprivate static class
A custom WALCellCodec in which we can inject failure.(package private) static class
private static class
A proxy around FSDataInputStream which can report if close() was called. -
Field Summary
Modifier and TypeFieldDescriptionstatic final HBaseClassTestRule
private static org.apache.hadoop.hdfs.MiniDFSCluster
protected static org.apache.hadoop.conf.Configuration
private org.apache.hadoop.hbase.ServerName
final org.junit.rules.TestName
protected org.apache.hadoop.fs.Path
protected org.apache.hadoop.fs.FileSystem
protected static org.apache.hadoop.fs.Path
protected static org.apache.hadoop.fs.Path
private static final org.slf4j.Logger
protected static final HBaseTestingUtility
protected org.apache.hadoop.hbase.wal.WALFactory
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Test new HDFS-265 sync.void
void
setUp()
static void
void
tearDown()
static void
void
void
void
void
void
void
Tests that we can write out an edit, close, and then read it back in again.void
void
void
void
Just write multiple logs then split.void
Test that we can visit entries before they are appendedvoid
A loaded WAL coprocessor won't break existing WAL test cases.void
private void
verifySplits
(List<org.apache.hadoop.fs.Path> splits, int howmany)
-
Field Details
-
CLASS_RULE
-
LOG
-
conf
-
cluster
-
TEST_UTIL
-
hbaseDir
-
hbaseWALDir
-
fs
-
dir
-
wals
-
currentServername
-
currentTest
-
-
Constructor Details
-
TestWALFactory
public TestWALFactory()
-
-
Method Details
-
setUp
- Throws:
Exception
-
tearDown
- Throws:
Exception
-
setUpBeforeClass
- Throws:
Exception
-
tearDownAfterClass
- Throws:
Exception
-
canCloseSingleton
- Throws:
IOException
-
testSplit
Just write multiple logs then split. Before fix for HADOOP-2283, this would fail.- Throws:
IOException
-
Broken_testSync
Test new HDFS-265 sync.- Throws:
Exception
-
verifySplits
- Throws:
IOException
-
testAppendClose
- Throws:
Exception
-
testEditAdd
Tests that we can write out an edit, close, and then read it back in again.- Throws:
IOException
-
testAppend
- Throws:
IOException
-
testVisitors
Test that we can visit entries before they are appended- Throws:
Exception
-
testWALCoprocessorLoaded
A loaded WAL coprocessor won't break existing WAL test cases.- Throws:
Exception
-
testWALProviders
- Throws:
IOException
-
testOnlySetWALProvider
- Throws:
IOException
-
testOnlySetMetaWALProvider
- Throws:
IOException
-
testDefaultProvider
- Throws:
IOException
-
testCustomProvider
- Throws:
IOException
-
testCustomMetaProvider
- Throws:
IOException
-
testReaderClosedOnBadCodec
- Throws:
IOException
-