public class TestPrefetchWithBucketCache extends Object
Modifier and Type | Field and Description |
---|---|
private org.apache.hadoop.hbase.io.hfile.BlockCache |
blockCache |
private org.apache.hadoop.hbase.io.hfile.CacheConfig |
cacheConf |
static HBaseClassTestRule |
CLASS_RULE |
private org.apache.hadoop.conf.Configuration |
conf |
private static int |
DATA_BLOCK_SIZE |
private org.apache.hadoop.fs.FileSystem |
fs |
private static org.slf4j.Logger |
LOG |
org.junit.rules.TestName |
name |
private static int |
NUM_VALID_KEY_TYPES |
private static HBaseTestingUtil |
TEST_UTIL |
Constructor and Description |
---|
TestPrefetchWithBucketCache() |
Modifier and Type | Method and Description |
---|---|
private org.apache.hadoop.hbase.io.hfile.HFile.Reader |
createReaderAndWaitForPrefetchInterruption(org.apache.hadoop.fs.Path storeFilePath) |
static org.apache.hadoop.hbase.KeyValue.Type |
generateKeyType(Random rand) |
private void |
readStoreFile(org.apache.hadoop.fs.Path storeFilePath) |
private void |
readStoreFile(org.apache.hadoop.fs.Path storeFilePath,
BiFunction<org.apache.hadoop.hbase.io.hfile.HFile.Reader,Long,org.apache.hadoop.hbase.io.hfile.HFileBlock> readFunction,
BiConsumer<org.apache.hadoop.hbase.io.hfile.BlockCacheKey,org.apache.hadoop.hbase.io.hfile.HFileBlock> validationFunction) |
void |
setUp() |
void |
tearDown() |
void |
testPrefetchDoesntInterruptInMemoryOnCapacity() |
void |
testPrefetchDoesntOverwork() |
void |
testPrefetchInterruptOnCapacity() |
private org.apache.hadoop.fs.Path |
writeStoreFile(String fname,
org.apache.hadoop.hbase.io.hfile.HFileContext context,
int numKVs) |
private org.apache.hadoop.fs.Path |
writeStoreFile(String fname,
int numKVs) |
private static final org.slf4j.Logger LOG
public static final HBaseClassTestRule CLASS_RULE
public org.junit.rules.TestName name
private static final HBaseTestingUtil TEST_UTIL
private static final int NUM_VALID_KEY_TYPES
private static final int DATA_BLOCK_SIZE
private org.apache.hadoop.conf.Configuration conf
private org.apache.hadoop.hbase.io.hfile.CacheConfig cacheConf
private org.apache.hadoop.fs.FileSystem fs
private org.apache.hadoop.hbase.io.hfile.BlockCache blockCache
public TestPrefetchWithBucketCache()
public void setUp() throws IOException
IOException
public void tearDown()
public void testPrefetchDoesntOverwork() throws Exception
Exception
public void testPrefetchInterruptOnCapacity() throws Exception
Exception
public void testPrefetchDoesntInterruptInMemoryOnCapacity() throws Exception
Exception
private void readStoreFile(org.apache.hadoop.fs.Path storeFilePath) throws Exception
Exception
private void readStoreFile(org.apache.hadoop.fs.Path storeFilePath, BiFunction<org.apache.hadoop.hbase.io.hfile.HFile.Reader,Long,org.apache.hadoop.hbase.io.hfile.HFileBlock> readFunction, BiConsumer<org.apache.hadoop.hbase.io.hfile.BlockCacheKey,org.apache.hadoop.hbase.io.hfile.HFileBlock> validationFunction) throws Exception
Exception
private org.apache.hadoop.hbase.io.hfile.HFile.Reader createReaderAndWaitForPrefetchInterruption(org.apache.hadoop.fs.Path storeFilePath) throws Exception
Exception
private org.apache.hadoop.fs.Path writeStoreFile(String fname, int numKVs) throws IOException
IOException
private org.apache.hadoop.fs.Path writeStoreFile(String fname, org.apache.hadoop.hbase.io.hfile.HFileContext context, int numKVs) throws IOException
IOException
public static org.apache.hadoop.hbase.KeyValue.Type generateKeyType(Random rand)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.