Class TestDurability
java.lang.Object
org.apache.hadoop.hbase.regionserver.wal.TestDurability
Tests for WAL write durability
-
Field Summary
Modifier and TypeFieldDescriptionstatic final HBaseClassTestRule
private static org.apache.hadoop.hdfs.MiniDFSCluster
private static byte[]
private static org.apache.hadoop.conf.Configuration
private static org.apache.hadoop.fs.Path
private static byte[]
private static org.apache.hadoop.fs.FileSystem
org.junit.rules.TestName
private static byte[]
private static final HBaseTestingUtility
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprivate org.apache.hadoop.hbase.regionserver.HRegion
createHRegion
(org.apache.hadoop.hbase.client.TableDescriptor td, org.apache.hadoop.hbase.client.RegionInfo info, String dir, org.apache.hadoop.hbase.wal.WAL wal, org.apache.hadoop.hbase.client.Durability durability) private org.apache.hadoop.hbase.regionserver.HRegion
createHRegion
(org.apache.hadoop.hbase.wal.WALFactory wals, org.apache.hadoop.hbase.client.Durability durability) data()
private org.apache.hadoop.hbase.client.Put
newPut
(org.apache.hadoop.hbase.client.Durability durability) void
setUp()
static void
void
tearDown()
static void
void
void
void
Test when returnResults set to false in increment it should not return the result instead it resturn null.private void
verifyWALCount
(org.apache.hadoop.hbase.wal.WALFactory wals, org.apache.hadoop.hbase.wal.WAL log, int expected)
-
Field Details
-
CLASS_RULE
-
TEST_UTIL
-
FS
-
CLUSTER
-
CONF
-
DIR
-
FAMILY
-
ROW
-
COL
-
walProvider
-
name
-
-
Constructor Details
-
TestDurability
public TestDurability()
-
-
Method Details
-
data
-
setUpBeforeClass
- Throws:
Exception
-
tearDownAfterClass
- Throws:
Exception
-
setUp
-
tearDown
- Throws:
IOException
-
testDurability
- Throws:
Exception
-
testIncrement
- Throws:
Exception
-
testIncrementWithReturnResultsSetToFalse
Test when returnResults set to false in increment it should not return the result instead it resturn null.- Throws:
Exception
-
newPut
private org.apache.hadoop.hbase.client.Put newPut(org.apache.hadoop.hbase.client.Durability durability) -
verifyWALCount
private void verifyWALCount(org.apache.hadoop.hbase.wal.WALFactory wals, org.apache.hadoop.hbase.wal.WAL log, int expected) throws Exception - Throws:
Exception
-
createHRegion
private org.apache.hadoop.hbase.regionserver.HRegion createHRegion(org.apache.hadoop.hbase.wal.WALFactory wals, org.apache.hadoop.hbase.client.Durability durability) throws IOException - Throws:
IOException
-
createHRegion
private org.apache.hadoop.hbase.regionserver.HRegion createHRegion(org.apache.hadoop.hbase.client.TableDescriptor td, org.apache.hadoop.hbase.client.RegionInfo info, String dir, org.apache.hadoop.hbase.wal.WAL wal, org.apache.hadoop.hbase.client.Durability durability) throws IOException - Throws:
IOException
-