public class TestHFileScannerImplReferenceCount extends Object
Modifier and Type | Field and Description |
---|---|
private org.apache.hadoop.hbase.io.ByteBuffAllocator |
allocator |
org.junit.rules.TestName |
CASE |
private static int |
CELL_COUNT |
static HBaseClassTestRule |
CLASS_RULE |
private org.apache.hadoop.conf.Configuration |
conf |
private static byte[] |
FAMILY |
private org.apache.hadoop.hbase.Cell |
firstCell |
private org.apache.hadoop.fs.FileSystem |
fs |
private org.apache.hadoop.fs.Path |
hfilePath |
String |
ioengine |
private static org.slf4j.Logger |
LOG |
private static byte[] |
QUALIFIER |
private org.apache.hadoop.hbase.Cell |
secondCell |
private static byte[] |
SUFFIX |
private static HBaseTestingUtility |
UTIL |
private org.apache.hadoop.fs.Path |
workDir |
Constructor and Description |
---|
TestHFileScannerImplReferenceCount() |
Modifier and Type | Method and Description |
---|---|
private void |
assertRefCnt(org.apache.hadoop.hbase.io.hfile.HFileBlock block,
int value) |
static Collection<Object[]> |
data() |
private static byte[] |
randLongBytes() |
void |
setUp() |
static void |
setUpBeforeClass() |
void |
tearDown() |
void |
testCompression() |
void |
testDataBlockEncoding() |
void |
testDataBlockEncodingAndCompression() |
void |
testDefault() |
void |
testDisabledBlockCache() |
private void |
testReleaseBlock(org.apache.hadoop.hbase.io.compress.Compression.Algorithm compression,
org.apache.hadoop.hbase.io.encoding.DataBlockEncoding encoding)
A careful UT for validating the reference count mechanism, if want to change this UT please
read the design doc in HBASE-21879 firstly and make sure that understand the refCnt design.
|
void |
testSeekBefore()
See HBASE-22480
|
void |
testWithLruBlockCache() |
private void |
waitBucketCacheFlushed(org.apache.hadoop.hbase.io.hfile.BlockCache cache) |
private void |
writeHFile(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path hfilePath,
org.apache.hadoop.hbase.io.compress.Compression.Algorithm compression,
org.apache.hadoop.hbase.io.encoding.DataBlockEncoding encoding,
int cellCount) |
public static final HBaseClassTestRule CLASS_RULE
public org.junit.rules.TestName CASE
private static final org.slf4j.Logger LOG
private static final HBaseTestingUtility UTIL
private static final byte[] FAMILY
private static final byte[] QUALIFIER
private static final byte[] SUFFIX
private static final int CELL_COUNT
private org.apache.hadoop.conf.Configuration conf
private org.apache.hadoop.fs.Path workDir
private org.apache.hadoop.fs.FileSystem fs
private org.apache.hadoop.fs.Path hfilePath
private org.apache.hadoop.hbase.Cell firstCell
private org.apache.hadoop.hbase.Cell secondCell
private org.apache.hadoop.hbase.io.ByteBuffAllocator allocator
public TestHFileScannerImplReferenceCount()
public static Collection<Object[]> data()
private static byte[] randLongBytes()
public static void setUpBeforeClass()
public void setUp() throws IOException
IOException
public void tearDown() throws IOException
IOException
private void waitBucketCacheFlushed(org.apache.hadoop.hbase.io.hfile.BlockCache cache) throws InterruptedException
InterruptedException
private void writeHFile(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path hfilePath, org.apache.hadoop.hbase.io.compress.Compression.Algorithm compression, org.apache.hadoop.hbase.io.encoding.DataBlockEncoding encoding, int cellCount) throws IOException
IOException
private void testReleaseBlock(org.apache.hadoop.hbase.io.compress.Compression.Algorithm compression, org.apache.hadoop.hbase.io.encoding.DataBlockEncoding encoding) throws Exception
Exception
public void testSeekBefore() throws Exception
Exception
private void assertRefCnt(org.apache.hadoop.hbase.io.hfile.HFileBlock block, int value)
public void testDefault() throws Exception
Exception
public void testCompression() throws Exception
Exception
public void testDataBlockEncoding() throws Exception
Exception
public void testDataBlockEncodingAndCompression() throws Exception
Exception
public void testWithLruBlockCache() throws Exception
Exception
public void testDisabledBlockCache() throws Exception
Exception
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.