HBASE-11696 Make CombinedBlockCache resizable.

This commit is contained in:
anoopsjohn 2014-08-19 17:32:50 +05:30
parent fd4dfb489a
commit 3c13e8f3ce
1 changed files with 6 additions and 1 deletions

View File

@ -36,7 +36,7 @@ import org.apache.hadoop.hbase.io.hfile.bucket.BucketCache;
*
*/
@InterfaceAudience.Private
public class CombinedBlockCache implements BlockCache, HeapSize {
public class CombinedBlockCache implements ResizableBlockCache, HeapSize {
private final LruBlockCache lruCache;
private final BucketCache bucketCache;
private final CombinedCacheStats combinedCacheStats;
@ -207,4 +207,9 @@ public class CombinedBlockCache implements BlockCache, HeapSize {
public BlockCache[] getBlockCaches() {
return new BlockCache [] {this.lruCache, this.bucketCache};
}
@Override
public void setMaxSize(long size) {
this.lruCache.setMaxSize(size);
}
}