Package org.apache.hadoop.hbase.io.hfile
Class CacheTestUtils
java.lang.Object
org.apache.hadoop.hbase.io.hfile.CacheTestUtils
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic CacheTestUtils.HFileBlockPair[]
generateHFileBlocks
(int blockSize, int numBlocks) static void
getBlockAndAssertEquals
(org.apache.hadoop.hbase.io.hfile.BlockCache cache, org.apache.hadoop.hbase.io.hfile.BlockCacheKey key, org.apache.hadoop.hbase.io.hfile.Cacheable blockToCache, ByteBuffer destBuffer, ByteBuffer expectedBuffer) static void
hammerSingleKey
(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int numThreads, int numQueries) static void
testCacheMultiThreaded
(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int blockSize, int numThreads, int numQueries, double passingScore) static void
testCacheSimple
(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int blockSize, int numBlocks) static void
testHeapSizeChanges
(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int blockSize) Just checks if heapsize grows when something is cached, and gets smaller when the same object is evicted
-
Field Details
-
includesMemstoreTS
- See Also:
-
-
Constructor Details
-
CacheTestUtils
public CacheTestUtils()
-
-
Method Details
-
testHeapSizeChanges
public static void testHeapSizeChanges(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int blockSize) Just checks if heapsize grows when something is cached, and gets smaller when the same object is evicted -
testCacheMultiThreaded
public static void testCacheMultiThreaded(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int blockSize, int numThreads, int numQueries, double passingScore) throws Exception - Throws:
Exception
-
testCacheSimple
public static void testCacheSimple(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int blockSize, int numBlocks) throws Exception - Throws:
Exception
-
hammerSingleKey
public static void hammerSingleKey(org.apache.hadoop.hbase.io.hfile.BlockCache toBeTested, int numThreads, int numQueries) throws Exception - Throws:
Exception
-
generateHFileBlocks
-
getBlockAndAssertEquals
public static void getBlockAndAssertEquals(org.apache.hadoop.hbase.io.hfile.BlockCache cache, org.apache.hadoop.hbase.io.hfile.BlockCacheKey key, org.apache.hadoop.hbase.io.hfile.Cacheable blockToCache, ByteBuffer destBuffer, ByteBuffer expectedBuffer)
-