Package org.apache.hadoop.hbase.mob
Class TestMobStoreScanner
java.lang.Object
org.apache.hadoop.hbase.mob.TestMobStoreScanner
-
Field Summary
Modifier and TypeFieldDescriptionprivate static org.apache.hadoop.hbase.client.Admin
static final HBaseClassTestRule
private org.apache.hadoop.conf.Configuration
private static long
private static org.apache.hadoop.hbase.HTableDescriptor
private static final byte[]
private org.apache.hadoop.fs.FileSystem
private static org.apache.hadoop.hbase.HColumnDescriptor
org.junit.rules.TestName
private static final byte[]
private static final byte[]
protected final byte[]
private static final byte[]
private static final byte[]
private static org.apache.hadoop.hbase.client.Table
private static final HBaseTestingUtility
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprivate static void
assertIsMobReference
(org.apache.hadoop.hbase.Cell cell, byte[] row, byte[] family, byte[] value, org.apache.hadoop.hbase.TableName tn) Assert the value is store in mob.private static void
assertNotMobReference
(org.apache.hadoop.hbase.Cell cell, byte[] row, byte[] family, byte[] value) Assert the value is not store in mob.private void
createRecordAndCorruptMobFile
(org.apache.hadoop.hbase.TableName tn, byte[] row, byte[] family, byte[] qf, byte[] value) private static byte[]
generateMobValue
(int size) Generate the mob value.private org.apache.hadoop.fs.Path
getFlushedMobFile
(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.hbase.TableName table, String family) void
setScan
(org.apache.hadoop.hbase.client.Scan scan, boolean reversed, boolean mobScanRaw) Set the scan attributevoid
setUp
(long threshold, org.apache.hadoop.hbase.TableName tn) static void
static void
private void
testGet
(org.apache.hadoop.hbase.TableName tableName, boolean reversed, boolean doFlush) private void
testGetFromArchive
(boolean reversed) private void
testGetFromFiles
(boolean reversed) private void
testGetFromMemStore
(boolean reversed) void
private void
testGetReferences
(boolean reversed) void
private void
testMobThreshold
(boolean reversed) void
void
void
void
-
Field Details
-
CLASS_RULE
-
TEST_UTIL
-
row1
-
row2
-
family
-
qf1
-
qf2
-
qf3
-
table
-
admin
-
hcd
-
desc
-
defaultThreshold
-
fs
-
conf
-
name
-
-
Constructor Details
-
TestMobStoreScanner
public TestMobStoreScanner()
-
-
Method Details
-
setUpBeforeClass
- Throws:
Exception
-
tearDownAfterClass
- Throws:
Exception
-
setUp
- Throws:
Exception
-
generateMobValue
Generate the mob value.- Parameters:
size
- the size of the value- Returns:
- the mob value generated
-
setScan
Set the scan attribute- Parameters:
reversed
- if true, scan will be backward ordermobScanRaw
- if true, scan will get the mob reference
-
testMobStoreScanner
- Throws:
Exception
-
testReversedMobStoreScanner
- Throws:
Exception
-
testGetMassive
- Throws:
Exception
-
testReadPt
- Throws:
Exception
-
testReadFromCorruptMobFilesWithReadEmptyValueOnMobCellMiss
- Throws:
Exception
-
testReadFromCorruptMobFiles
- Throws:
Exception
-
createRecordAndCorruptMobFile
private void createRecordAndCorruptMobFile(org.apache.hadoop.hbase.TableName tn, byte[] row, byte[] family, byte[] qf, byte[] value) throws IOException - Throws:
IOException
-
getFlushedMobFile
private org.apache.hadoop.fs.Path getFlushedMobFile(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.hbase.TableName table, String family) throws IOException - Throws:
IOException
-
testGetFromFiles
- Throws:
Exception
-
testGetFromMemStore
- Throws:
Exception
-
testGet
private void testGet(org.apache.hadoop.hbase.TableName tableName, boolean reversed, boolean doFlush) throws Exception - Throws:
Exception
-
testGetReferences
- Throws:
Exception
-
testMobThreshold
- Throws:
Exception
-
testGetFromArchive
- Throws:
Exception
-
assertNotMobReference
private static void assertNotMobReference(org.apache.hadoop.hbase.Cell cell, byte[] row, byte[] family, byte[] value) throws IOException Assert the value is not store in mob.- Throws:
IOException
-
assertIsMobReference
private static void assertIsMobReference(org.apache.hadoop.hbase.Cell cell, byte[] row, byte[] family, byte[] value, org.apache.hadoop.hbase.TableName tn) throws IOException Assert the value is store in mob.- Throws:
IOException
-