@InterfaceAudience.Private public class InclusiveCombinedBlockCache extends CombinedBlockCache
CombinedBlockCache.CombinedCacheStats
combinedCacheStats, l2Cache, onHeapCache
构造器和说明 |
---|
InclusiveCombinedBlockCache(LruBlockCache l1,
BlockCache l2) |
限定符和类型 | 方法和说明 |
---|---|
void |
cacheBlock(BlockCacheKey cacheKey,
Cacheable buf,
boolean inMemory)
Add block to cache.
|
boolean |
evictBlock(BlockCacheKey cacheKey)
Evict block from cache.
|
Cacheable |
getBlock(BlockCacheKey cacheKey,
boolean caching,
boolean repeat,
boolean updateCacheMetrics)
Fetch block from cache.
|
cacheBlock, evictBlocksByHfileName, getBlockCaches, getBlockCount, getCurrentDataSize, getCurrentSize, getDataBlockCount, getFreeSize, getMaxSize, getOnHeapCache, getRefCount, getStats, heapSize, iterator, returnBlock, setMaxSize, shutdown, size
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
public InclusiveCombinedBlockCache(LruBlockCache l1, BlockCache l2)
public Cacheable getBlock(BlockCacheKey cacheKey, boolean caching, boolean repeat, boolean updateCacheMetrics)
BlockCache
getBlock
在接口中 BlockCache
getBlock
在类中 CombinedBlockCache
cacheKey
- Block to fetch.caching
- Whether this request has caching enabled (used for stats)repeat
- Whether this is a repeat lookup for the same block
(used to avoid double counting cache misses when doing double-check locking)updateCacheMetrics
- Whether to update cache metrics or notpublic void cacheBlock(BlockCacheKey cacheKey, Cacheable buf, boolean inMemory)
BlockCache
cacheBlock
在接口中 BlockCache
cacheBlock
在类中 CombinedBlockCache
cacheKey
- The block's cache key.buf
- The block contents wrapped in a ByteBuffer.inMemory
- Whether block should be treated as in-memory. This parameter is only useful for
the L1 lru cache.public boolean evictBlock(BlockCacheKey cacheKey)
BlockCache
evictBlock
在接口中 BlockCache
evictBlock
在类中 CombinedBlockCache
cacheKey
- Block to evictCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.