blob: c74a9325114145be33ada8f46581c35d8d7d0959 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>BucketCache (Apache HBase 4.0.0-alpha-1-SNAPSHOT API)</title>
<link rel="stylesheet" type="text/css" href="../../../../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="BucketCache (Apache HBase 4.0.0-alpha-1-SNAPSHOT API)";
}
}
catch(err) {
}
//-->
var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10,"i27":10,"i28":10,"i29":9,"i30":10,"i31":10,"i32":10,"i33":10,"i34":10,"i35":10,"i36":10,"i37":9,"i38":10,"i39":10,"i40":10,"i41":10,"i42":10,"i43":10,"i44":10,"i45":10,"i46":10,"i47":10,"i48":10,"i49":10,"i50":10,"i51":10,"i52":9,"i53":10,"i54":10,"i55":10,"i56":10,"i57":10,"i58":10,"i59":10,"i60":10,"i61":10,"i62":10,"i63":10,"i64":10,"i65":10,"i66":10,"i67":10,"i68":10,"i69":10,"i70":10,"i71":10,"i72":10,"i73":10,"i74":10,"i75":10,"i76":10,"i77":10,"i78":10,"i79":10,"i80":10,"i81":10,"i82":10,"i83":10,"i84":10};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/BucketCache.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocatorException.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.BucketEntryGroup.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../../../index.html?org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html" target="_top">Frames</a></li>
<li><a href="BucketCache.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li><a href="#nested.class.summary">Nested</a>&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field.detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.hadoop.hbase.io.hfile.bucket</div>
<h2 title="Class BucketCache" class="title">Class BucketCache</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li>org.apache.hadoop.hbase.io.hfile.bucket.BucketCache</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CachedBlock.html" title="interface in org.apache.hadoop.hbase.io.hfile">CachedBlock</a>&gt;, <a href="../../../../../../../org/apache/hadoop/hbase/io/HeapSize.html" title="interface in org.apache.hadoop.hbase.io">HeapSize</a>, <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></dd>
</dl>
<hr>
<br>
<pre>@InterfaceAudience.Private
public class <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.114">BucketCache</a>
extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>
implements <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a>, <a href="../../../../../../../org/apache/hadoop/hbase/io/HeapSize.html" title="interface in org.apache.hadoop.hbase.io">HeapSize</a></pre>
<div class="block">BucketCache uses <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocator.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketAllocator</code></a> to allocate/free blocks, and uses BucketCache#ramCache
and BucketCache#backingMap in order to determine if a given element is in the cache. The bucket
cache can use off-heap memory <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/ByteBufferIOEngine.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>ByteBufferIOEngine</code></a> or mmap
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/ExclusiveMemoryMmapIOEngine.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>ExclusiveMemoryMmapIOEngine</code></a> or pmem <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/SharedMemoryMmapIOEngine.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>SharedMemoryMmapIOEngine</code></a> or local files
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/FileIOEngine.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>FileIOEngine</code></a> to store/read the block data.
<p>
Eviction is via a similar algorithm as used in
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/LruBlockCache.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>LruBlockCache</code></a>
<p>
BucketCache can be used as mainly a block cache (see
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CombinedBlockCache.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>CombinedBlockCache</code></a>), combined with a BlockCache to
decrease CMS GC and heap fragmentation.
<p>
It also can be used as a secondary cache (e.g. using a file on ssd/fusionio to store blocks) to
enlarge cache space via a victim cache.</div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== NESTED CLASS SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="nested.class.summary">
<!-- -->
</a>
<h3>Nested Class Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Nested Class Summary table, listing nested classes, and an explanation">
<caption><span>Nested Classes</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Class and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.BucketEntryGroup.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.BucketEntryGroup</a></span></code>
<div class="block">Used to group bucket entries into priority buckets.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) static class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMCache.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMCache</a></span></code>
<div class="block">Wrapped the delegate ConcurrentMap with maintaining its block's reference count.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a></span></code>
<div class="block">Block Entry stored in the memory with key,data and so on</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private static class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.StatisticsThread.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.StatisticsThread</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) class&nbsp;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.WriterThread.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.WriterThread</a></span></code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.summary">
<!-- -->
</a>
<h3>Field Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ACCEPT_FACTOR_CONFIG_NAME">ACCEPT_FACTOR_CONFIG_NAME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#acceptableFactor">acceptableFactor</a></span></code>
<div class="block">Acceptable size of cache (no evictions if size < acceptable)</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicLong.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicLong</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#accessCount">accessCount</a></span></code>
<div class="block">Cache access count (sequential ID)</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#algorithm">algorithm</a></span></code>
<div class="block">Use <a href="https://docs.oracle.com/javase/8/docs/api/java/security/MessageDigest.html?is-external=true" title="class or interface in java.security"><code>MessageDigest</code></a> class's encryption algorithms to check persistent file
integrity, default algorithm is MD5</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ALLOCATION_FAIL_LOG_TIME_PERIOD">ALLOCATION_FAIL_LOG_TIME_PERIOD</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#allocFailLogPrevTs">allocFailLogPrevTs</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>,<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap">backingMap</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicBoolean.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicBoolean</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMapValidated">backingMapValidated</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/LongAdder.html?is-external=true" title="class or interface in java.util.concurrent.atomic">LongAdder</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#blockNumber">blockNumber</a></span></code>
<div class="block">Current number of cached elements</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) <a href="https://docs.oracle.com/javase/8/docs/api/java/util/NavigableSet.html?is-external=true" title="class or interface in java.util">NavigableSet</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#blocksByHFile">blocksByHFile</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#blockSize">blockSize</a></span></code>
<div class="block">Approximate block size</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocator.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketAllocator</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#bucketAllocator">bucketAllocator</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#bucketcachePersistInterval">bucketcachePersistInterval</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheCapacity">cacheCapacity</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheEnabled">cacheEnabled</a></span></code>
<div class="block">Flag if the cache is enabled or not...</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCachePersister.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCachePersister</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cachePersister">cachePersister</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCacheStats.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCacheStats</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheStats">cacheStats</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private static float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_ACCEPT_FACTOR">DEFAULT_ACCEPT_FACTOR</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_CACHE_WAIT_TIME">DEFAULT_CACHE_WAIT_TIME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_ERROR_TOLERATION_DURATION">DEFAULT_ERROR_TOLERATION_DURATION</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_EXTRA_FREE_FACTOR">DEFAULT_EXTRA_FREE_FACTOR</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_FILE_VERIFY_ALGORITHM">DEFAULT_FILE_VERIFY_ALGORITHM</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_FREE_ENTIRE_BLOCK_FACTOR">DEFAULT_FREE_ENTIRE_BLOCK_FACTOR</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) static float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_MEMORY_FACTOR">DEFAULT_MEMORY_FACTOR</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_MIN_FACTOR">DEFAULT_MIN_FACTOR</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) static float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_MULTI_FACTOR">DEFAULT_MULTI_FACTOR</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_QUEUE_ADDITION_WAIT_TIME">DEFAULT_QUEUE_ADDITION_WAIT_TIME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) static float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_SINGLE_FACTOR">DEFAULT_SINGLE_FACTOR</a></span></code>
<div class="block">Priority buckets</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_WRITER_QUEUE_ITEMS">DEFAULT_WRITER_QUEUE_ITEMS</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#DEFAULT_WRITER_THREADS">DEFAULT_WRITER_THREADS</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#EXTRA_FREE_FACTOR_CONFIG_NAME">EXTRA_FREE_FACTOR_CONFIG_NAME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#extraFreeFactor">extraFreeFactor</a></span></code>
<div class="block">Free this floating point factor of extra blocks when evicting.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#FILE_VERIFY_ALGORITHM">FILE_VERIFY_ALGORITHM</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#freeInProgress">freeInProgress</a></span></code>
<div class="block">Volatile boolean to track if free space is in process or not</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/locks/Lock.html?is-external=true" title="class or interface in java.util.concurrent.locks">Lock</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#freeSpaceLock">freeSpaceLock</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="../../../../../../../org/apache/hadoop/hbase/util/Pair.html" title="class in org.apache.hadoop.hbase.util">Pair</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#fullyCachedFiles">fullyCachedFiles</a></span></code>
<div class="block">Map of hFile -> Region -> File size.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/LongAdder.html?is-external=true" title="class or interface in java.util.concurrent.atomic">LongAdder</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#heapSize">heapSize</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/IOEngine.html" title="interface in org.apache.hadoop.hbase.io.hfile.bucket">IOEngine</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ioEngine">ioEngine</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ioErrorStartTime">ioErrorStartTime</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ioErrorsTolerationDuration">ioErrorsTolerationDuration</a></span></code>
<div class="block">Duration of IO errors tolerated before we disable cache, 1 min as default</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicBoolean.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicBoolean</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#isCacheInconsistent">isCacheInconsistent</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private static org.slf4j.Logger</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#LOG">LOG</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#MEMORY_FACTOR_CONFIG_NAME">MEMORY_FACTOR_CONFIG_NAME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#memoryFactor">memoryFactor</a></span></code>
<div class="block">In-memory bucket size</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#MIN_FACTOR_CONFIG_NAME">MIN_FACTOR_CONFIG_NAME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#minFactor">minFactor</a></span></code>
<div class="block">Minimum threshold of cache (when evicting, evict until size < min)</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#MULTI_FACTOR_CONFIG_NAME">MULTI_FACTOR_CONFIG_NAME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#multiFactor">multiFactor</a></span></code>
<div class="block">Multiple access bucket size</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) <a href="../../../../../../../org/apache/hadoop/hbase/util/IdReadWriteLock.html" title="class in org.apache.hadoop.hbase.util">IdReadWriteLock</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#offsetLock">offsetLock</a></span></code>
<div class="block">A ReentrantReadWriteLock to lock on a particular block identified by offset.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#persistencePath">persistencePath</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#QUEUE_ADDITION_WAIT_TIME">QUEUE_ADDITION_WAIT_TIME</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#queueAdditionWaitTime">queueAdditionWaitTime</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMCache.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMCache</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ramCache">ramCache</a></span></code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/LongAdder.html?is-external=true" title="class or interface in java.util.concurrent.atomic">LongAdder</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#realCacheSize">realCacheSize</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#regionCachedSize">regionCachedSize</a></span></code>
<div class="block">Map of region -> total size of the region prefetched on this region server.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/ScheduledExecutorService.html?is-external=true" title="class or interface in java.util.concurrent">ScheduledExecutorService</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#scheduleThreadPool">scheduleThreadPool</a></span></code>
<div class="block">Statistics thread schedule pool (for heavy debugging, could remove)</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#SINGLE_FACTOR_CONFIG_NAME">SINGLE_FACTOR_CONFIG_NAME</a></span></code>
<div class="block">Priority buckets config</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#singleFactor">singleFactor</a></span></code>
<div class="block">Single access bucket size</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#statThreadPeriod">statThreadPeriod</a></span></code>
<div class="block">Statistics thread</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>private static boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#STRONG_REF_DEFAULT">STRONG_REF_DEFAULT</a></span></code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>private static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#STRONG_REF_KEY">STRONG_REF_KEY</a></span></code>
<div class="block">Use strong reference for offsetLock or not</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>(package private) <a href="https://docs.oracle.com/javase/8/docs/api/java/util/ArrayList.html?is-external=true" title="class or interface in java.util">ArrayList</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/BlockingQueue.html?is-external=true" title="class or interface in java.util.concurrent">BlockingQueue</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#writerQueues">writerQueues</a></span></code>
<div class="block">A list of writer queues.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>(package private) <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.WriterThread.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.WriterThread</a>[]</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#writerThreads">writerThreads</a></span></code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#BucketCache-java.lang.String-long-int-int:A-int-int-java.lang.String-">BucketCache</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioEngineName,
long&nbsp;capacity,
int&nbsp;blockSize,
int[]&nbsp;bucketSizes,
int&nbsp;writerThreadNum,
int&nbsp;writerQLen,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;persistencePath)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colOne"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#BucketCache-java.lang.String-long-int-int:A-int-int-java.lang.String-int-org.apache.hadoop.conf.Configuration-">BucketCache</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioEngineName,
long&nbsp;capacity,
int&nbsp;blockSize,
int[]&nbsp;bucketSizes,
int&nbsp;writerThreadNum,
int&nbsp;writerQLen,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;persistencePath,
int&nbsp;ioErrorsTolerationDuration,
org.apache.hadoop.conf.Configuration&nbsp;conf)</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#acceptableSize--">acceptableSize</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#blockEvicted-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-boolean-boolean-">blockEvicted</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry,
boolean&nbsp;decrementBlockNumber,
boolean&nbsp;evictedByEvictionProcess)</code>
<div class="block">This method is invoked after the bucketEntry is removed from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a></div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#blockFitsIntoTheCache-org.apache.hadoop.hbase.io.hfile.HFileBlock-">blockFitsIntoTheCache</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/HFileBlock.html" title="class in org.apache.hadoop.hbase.io.hfile">HFileBlock</a>&nbsp;block)</code>
<div class="block">Checks whether there's enough space left in the cache to accommodate the passed block.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>private int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#bucketSizesAboveThresholdCount-float-">bucketSizesAboveThresholdCount</a></span>(float&nbsp;minFactor)</code>
<div class="block">Return the count of bucketSizeinfos still need free space</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-">cacheBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;buf)</code>
<div class="block">Cache the block with the specified name and buffer.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-">cacheBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory)</code>
<div class="block">Cache the block with the specified name and buffer.</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">cacheBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory,
boolean&nbsp;waitWhenCache)</code>
<div class="block">Cache the block with the specified name and buffer.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheBlockWithWait-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">cacheBlockWithWait</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory,
boolean&nbsp;wait)</code>
<div class="block">Cache the block to ramCache</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#cacheBlockWithWaitInternal-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">cacheBlockWithWaitInternal</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory,
boolean&nbsp;wait)</code>&nbsp;</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#checkIOErrorIsTolerated--">checkIOErrorIsTolerated</a></span>()</code>
<div class="block">Check whether we tolerate IO error this time.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>private <a href="../../../../../../../org/apache/hadoop/hbase/io/ByteBuffAllocator.Recycler.html" title="interface in org.apache.hadoop.hbase.io">ByteBuffAllocator.Recycler</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#createRecycler-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">createRecycler</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</code>
<div class="block">
Create the <a href="../../../../../../../org/apache/hadoop/hbase/io/ByteBuffAllocator.Recycler.html" title="interface in org.apache.hadoop.hbase.io"><code>ByteBuffAllocator.Recycler</code></a> for <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#refCnt"><code>BucketEntry.refCnt</code></a>,which would be used as
<a href="../../../../../../../org/apache/hadoop/hbase/nio/RefCnt.html#recycler"><code>RefCnt.recycler</code></a> of <code>HFileBlock#buf</code> returned from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-"><code>getBlock(org.apache.hadoop.hbase.io.hfile.BlockCacheKey, boolean, boolean, boolean)</code></a>.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/io/FileInputStream.html?is-external=true" title="class or interface in java.io">FileInputStream</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#deleteFileOnClose-java.io.File-">deleteFileOnClose</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a>&nbsp;file)</code>
<div class="block">Create an input stream that deletes the file after reading it.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#disableCache--">disableCache</a></span>()</code>
<div class="block">Used to shut down the cache -or- turn it off in the case of something broken.</div>
</td>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#doDrain-java.util.List-java.nio.ByteBuffer-">doDrain</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;entries,
<a href="https://docs.oracle.com/javase/8/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a>&nbsp;metaBuff)</code>
<div class="block">Flush the entries in ramCache to IOEngine and add bucket entry to backingMap.</div>
</td>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><code>private boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#doEvictBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-boolean-">doEvictBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry,
boolean&nbsp;evictedByEvictionProcess)</code>
<div class="block">Evict the <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> and <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a> and
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ramCache"><code>ramCache</code></a>.</div>
</td>
</tr>
<tr id="i15" class="rowColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#dumpPrefetchList--">dumpPrefetchList</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#evictBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">evictBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey)</code>
<div class="block">Try to evict the block from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile"><code>BlockCache</code></a> by force.</div>
</td>
</tr>
<tr id="i17" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#evictBlockIfNoRpcReferenced-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">evictBlockIfNoRpcReferenced</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;blockCacheKey)</code>
<div class="block">NOTE: This method is only for test.</div>
</td>
</tr>
<tr id="i18" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#evictBlocksByHfileName-java.lang.String-">evictBlocksByHfileName</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;hfileName)</code>
<div class="block">Evicts all blocks for a specific HFile.</div>
</td>
</tr>
<tr id="i19" class="rowColor">
<td class="colFirst"><code>(package private) boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#evictBucketEntryIfNoRpcReferenced-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">evictBucketEntryIfNoRpcReferenced</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;blockCacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</code>
<div class="block">Evict <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> and its corresponding <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> only if
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#isRpcRef--"><code>BucketEntry.isRpcRef()</code></a> is false.</div>
</td>
</tr>
<tr id="i20" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#fileCacheCompleted-org.apache.hadoop.fs.Path-long-">fileCacheCompleted</a></span>(org.apache.hadoop.fs.Path&nbsp;filePath,
long&nbsp;size)</code>&nbsp;</td>
</tr>
<tr id="i21" class="rowColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#fileNotFullyCached-java.lang.String-">fileNotFullyCached</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;hfileName)</code>&nbsp;</td>
</tr>
<tr id="i22" class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#finalize--">finalize</a></span>()</code>
<div class="block">Needed mostly for UTs that might run in the same VM and create different BucketCache instances
on different UT methods.</div>
</td>
</tr>
<tr id="i23" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#freeBucketEntry-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">freeBucketEntry</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</code>
<div class="block">Free the {<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> actually,which could only be invoked when the
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#refCnt"><code>BucketEntry.refCnt</code></a> becoming 0.</div>
</td>
</tr>
<tr id="i24" class="altColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#freeEntireBuckets-int-">freeEntireBuckets</a></span>(int&nbsp;completelyFreeBucketsNeeded)</code>
<div class="block">This method will find the buckets that are minimally occupied and are not reference counted and
will free them completely without any constraint on the access times of the elements, and as a
process will completely free at most the number of buckets passed, sometimes it might not due
to changing refCounts</div>
</td>
</tr>
<tr id="i25" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#freeSpace-java.lang.String-">freeSpace</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;why)</code>
<div class="block">Free the space if the used size reaches acceptableSize() or one size block couldn't be
allocated.</div>
</td>
</tr>
<tr id="i26" class="altColor">
<td class="colFirst"><code>(package private) float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getAcceptableFactor--">getAcceptableFactor</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i27" class="rowColor">
<td class="colFirst"><code>protected <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getAlgorithm--">getAlgorithm</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i28" class="altColor">
<td class="colFirst"><code>private <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getAllCacheKeysForFile-java.lang.String-">getAllCacheKeysForFile</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;hfileName)</code>&nbsp;</td>
</tr>
<tr id="i29" class="rowColor">
<td class="colFirst"><code>private static <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getAllocationFailWarningMessage-org.apache.hadoop.hbase.io.hfile.bucket.BucketAllocatorException-org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.RAMQueueEntry-">getAllocationFailWarningMessage</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocatorException.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketAllocatorException</a>&nbsp;fle,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&nbsp;re)</code>
<div class="block">Prepare and return a warning message for Bucket Allocator Exception</div>
</td>
</tr>
<tr id="i30" class="altColor">
<td class="colFirst"><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocator.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketAllocator</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getAllocator--">getAllocator</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i31" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>,<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBackingMap--">getBackingMap</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i32" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicBoolean.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicBoolean</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBackingMapValidated--">getBackingMapValidated</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i33" class="rowColor">
<td class="colFirst"><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-">getBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key,
boolean&nbsp;caching,
boolean&nbsp;repeat,
boolean&nbsp;updateCacheMetrics)</code>
<div class="block">Get the buffer of the block with the specified key.</div>
</td>
</tr>
<tr id="i34" class="altColor">
<td class="colFirst"><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a>[]</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlockCaches--">getBlockCaches</a></span>()</code>
<div class="block">Returns The list of sub blockcaches that make up this one; returns null if no sub caches.</div>
</td>
</tr>
<tr id="i35" class="rowColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlockCount--">getBlockCount</a></span>()</code>
<div class="block">Returns the number of blocks currently cached in the block cache.</div>
</td>
</tr>
<tr id="i36" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlockSize-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">getBlockSize</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key)</code>
<div class="block">Returns an Optional containing the size of the block related to the passed key.</div>
</td>
</tr>
<tr id="i37" class="rowColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBucketCacheFromCacheConfig-org.apache.hadoop.hbase.io.hfile.CacheConfig-">getBucketCacheFromCacheConfig</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CacheConfig.html" title="class in org.apache.hadoop.hbase.io.hfile">CacheConfig</a>&nbsp;cacheConf)</code>&nbsp;</td>
</tr>
<tr id="i38" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getCurrentDataSize--">getCurrentDataSize</a></span>()</code>
<div class="block">Returns the occupied size of data blocks, in bytes.</div>
</td>
</tr>
<tr id="i39" class="rowColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getCurrentSize--">getCurrentSize</a></span>()</code>
<div class="block">Returns the occupied size of the block cache, in bytes.</div>
</td>
</tr>
<tr id="i40" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getDataBlockCount--">getDataBlockCount</a></span>()</code>
<div class="block">Returns the number of data blocks currently cached in the block cache.</div>
</td>
</tr>
<tr id="i41" class="rowColor">
<td class="colFirst"><code>(package private) float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getExtraFreeFactor--">getExtraFreeFactor</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i42" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getFreeSize--">getFreeSize</a></span>()</code>
<div class="block">Returns the free size of the block cache, in bytes.</div>
</td>
</tr>
<tr id="i43" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="../../../../../../../org/apache/hadoop/hbase/util/Pair.html" title="class in org.apache.hadoop.hbase.util">Pair</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;&gt;&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getFullyCachedFiles--">getFullyCachedFiles</a></span>()</code>
<div class="block">Returns an Optional containing the map of files that have been fully cached (all its blocks are
present in the cache.</div>
</td>
</tr>
<tr id="i44" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getIoEngine--">getIoEngine</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i45" class="rowColor">
<td class="colFirst"><code>private <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/IOEngine.html" title="interface in org.apache.hadoop.hbase.io.hfile.bucket">IOEngine</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getIOEngineFromName-java.lang.String-long-java.lang.String-">getIOEngineFromName</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioEngineName,
long&nbsp;capacity,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;persistencePath)</code>
<div class="block">Get the IOEngine from the IO engine name</div>
</td>
</tr>
<tr id="i46" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getMaxSize--">getMaxSize</a></span>()</code>
<div class="block">Returns the Max size of the block cache, in bytes.</div>
</td>
</tr>
<tr id="i47" class="rowColor">
<td class="colFirst"><code>(package private) float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getMemoryFactor--">getMemoryFactor</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i48" class="altColor">
<td class="colFirst"><code>(package private) float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getMinFactor--">getMinFactor</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i49" class="rowColor">
<td class="colFirst"><code>(package private) float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getMultiFactor--">getMultiFactor</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i50" class="altColor">
<td class="colFirst"><code>(package private) long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getPartitionSize-float-">getPartitionSize</a></span>(float&nbsp;partitionFactor)</code>&nbsp;</td>
</tr>
<tr id="i51" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getPersistencePath--">getPersistencePath</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i52" class="altColor">
<td class="colFirst"><code>(package private) static <a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getRAMQueueEntries-java.util.concurrent.BlockingQueue-java.util.List-">getRAMQueueEntries</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/BlockingQueue.html?is-external=true" title="class or interface in java.util.concurrent">BlockingQueue</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;q,
<a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;receptacle)</code>
<div class="block">Blocks until elements available in <code>q</code> then tries to grab as many as possible before
returning.</div>
</td>
</tr>
<tr id="i53" class="rowColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getRealCacheSize--">getRealCacheSize</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i54" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getRegionCachedInfo--">getRegionCachedInfo</a></span>()</code>
<div class="block">Returns an Optional containing a map of regions and the percentage of how much of it has been
cached so far.</div>
</td>
</tr>
<tr id="i55" class="rowColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getRpcRefCount-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">getRpcRefCount</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey)</code>&nbsp;</td>
</tr>
<tr id="i56" class="altColor">
<td class="colFirst"><code>(package private) float</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getSingleFactor--">getSingleFactor</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i57" class="rowColor">
<td class="colFirst"><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CacheStats.html" title="class in org.apache.hadoop.hbase.io.hfile">CacheStats</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getStats--">getStats</a></span>()</code>
<div class="block">Get the statistics for this block cache.</div>
</td>
</tr>
<tr id="i58" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#heapSize--">heapSize</a></span>()</code>
<div class="block">Return the approximate 'exclusive deep size' of implementing object.</div>
</td>
</tr>
<tr id="i59" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#isAlreadyCached-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">isAlreadyCached</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key)</code>
<div class="block">Checks whether the block for the passed key is already cached.</div>
</td>
</tr>
<tr id="i60" class="altColor">
<td class="colFirst"><code>(package private) boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#isCacheEnabled--">isCacheEnabled</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i61" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#isCacheInconsistent--">isCacheInconsistent</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i62" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#isCachePersistenceEnabled--">isCachePersistenceEnabled</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i63" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#isCachePersistent--">isCachePersistent</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i64" class="altColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CachedBlock.html" title="interface in org.apache.hadoop.hbase.io.hfile">CachedBlock</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#iterator--">iterator</a></span>()</code>
<div class="block">Returns Iterator over the blocks in the cache.</div>
</td>
</tr>
<tr id="i65" class="rowColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#join--">join</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i66" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#logStats--">logStats</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i67" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#notifyFileCachingCompleted-org.apache.hadoop.fs.Path-int-int-long-">notifyFileCachingCompleted</a></span>(org.apache.hadoop.fs.Path&nbsp;fileName,
int&nbsp;totalBlockCount,
int&nbsp;dataBlockCount,
long&nbsp;size)</code>
<div class="block">Notifies the cache implementation that the given file has been fully cached (all its blocks
made into the cache).</div>
</td>
</tr>
<tr id="i68" class="altColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#parsePB-org.apache.hadoop.hbase.shaded.protobuf.generated.BucketCacheProtos.BucketCacheEntry-">parsePB</a></span>(org.apache.hadoop.hbase.shaded.protobuf.generated.BucketCacheProtos.BucketCacheEntry&nbsp;proto)</code>&nbsp;</td>
</tr>
<tr id="i69" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#persistToFile--">persistToFile</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i70" class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#putIntoBackingMap-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">putIntoBackingMap</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</code>
<div class="block">Put the new bucket entry into backingMap.</div>
</td>
</tr>
<tr id="i71" class="rowColor">
<td class="colFirst"><code>protected boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#removeFromRamCache-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">removeFromRamCache</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey)</code>&nbsp;</td>
</tr>
<tr id="i72" class="altColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#retrieveFromFile-int:A-">retrieveFromFile</a></span>(int[]&nbsp;bucketSizes)</code>&nbsp;</td>
</tr>
<tr id="i73" class="rowColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#sanityCheckConfigs--">sanityCheckConfigs</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i74" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#setCacheInconsistent-boolean-">setCacheInconsistent</a></span>(boolean&nbsp;setCacheInconsistent)</code>&nbsp;</td>
</tr>
<tr id="i75" class="rowColor">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&gt;</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#shouldCacheFile-java.lang.String-">shouldCacheFile</a></span>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;fileName)</code>
<div class="block">Checks whether blocks for the passed file should be cached or not.</div>
</td>
</tr>
<tr id="i76" class="altColor">
<td class="colFirst"><code>protected boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#shouldReplaceExistingCacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-">shouldReplaceExistingCacheBlock</a></span>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;newBlock)</code>&nbsp;</td>
</tr>
<tr id="i77" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#shutdown--">shutdown</a></span>()</code>
<div class="block">Shutdown the cache.</div>
</td>
</tr>
<tr id="i78" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#size--">size</a></span>()</code>
<div class="block">Returns the total size of the block cache, in bytes.</div>
</td>
</tr>
<tr id="i79" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#startBucketCachePersisterThread--">startBucketCachePersisterThread</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i80" class="altColor">
<td class="colFirst"><code>protected void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#startWriterThreads--">startWriterThreads</a></span>()</code>
<div class="block">Called by the constructor to start the writer threads.</div>
</td>
</tr>
<tr id="i81" class="rowColor">
<td class="colFirst"><code>(package private) void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#stopWriterThreads--">stopWriterThreads</a></span>()</code>
<div class="block">Only used in test</div>
</td>
</tr>
<tr id="i82" class="altColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#updateRegionCachedSize-org.apache.hadoop.fs.Path-long-">updateRegionCachedSize</a></span>(org.apache.hadoop.fs.Path&nbsp;filePath,
long&nbsp;cachedSize)</code>&nbsp;</td>
</tr>
<tr id="i83" class="rowColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#updateRegionSizeMapWhileRetrievingFromFile--">updateRegionSizeMapWhileRetrievingFromFile</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i84" class="altColor">
<td class="colFirst"><code>private void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#verifyCapacityAndClasses-long-java.lang.String-java.lang.String-">verifyCapacityAndClasses</a></span>(long&nbsp;capacitySize,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioclass,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;mapclass)</code>&nbsp;</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.org.apache.hadoop.hbase.io.hfile.BlockCache">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;org.apache.hadoop.hbase.io.hfile.<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></h3>
<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-org.apache.hadoop.hbase.io.hfile.BlockType-">getBlock</a>, <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#isMetaBlock-org.apache.hadoop.hbase.io.hfile.BlockType-">isMetaBlock</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Iterable">
<!-- -->
</a>
<h3>Methods inherited from interface&nbsp;java.lang.<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</a></h3>
<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#forEach-java.util.function.Consumer-" title="class or interface in java.lang">forEach</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#spliterator--" title="class or interface in java.lang">spliterator</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.detail">
<!-- -->
</a>
<h3>Field Detail</h3>
<a name="LOG">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>LOG</h4>
<pre>private static final&nbsp;org.slf4j.Logger <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.115">LOG</a></pre>
</li>
</ul>
<a name="SINGLE_FACTOR_CONFIG_NAME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>SINGLE_FACTOR_CONFIG_NAME</h4>
<pre>static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.118">SINGLE_FACTOR_CONFIG_NAME</a></pre>
<div class="block">Priority buckets config</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.SINGLE_FACTOR_CONFIG_NAME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="MULTI_FACTOR_CONFIG_NAME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>MULTI_FACTOR_CONFIG_NAME</h4>
<pre>static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.119">MULTI_FACTOR_CONFIG_NAME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.MULTI_FACTOR_CONFIG_NAME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="MEMORY_FACTOR_CONFIG_NAME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>MEMORY_FACTOR_CONFIG_NAME</h4>
<pre>static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.120">MEMORY_FACTOR_CONFIG_NAME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.MEMORY_FACTOR_CONFIG_NAME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="EXTRA_FREE_FACTOR_CONFIG_NAME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>EXTRA_FREE_FACTOR_CONFIG_NAME</h4>
<pre>static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.121">EXTRA_FREE_FACTOR_CONFIG_NAME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.EXTRA_FREE_FACTOR_CONFIG_NAME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="ACCEPT_FACTOR_CONFIG_NAME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>ACCEPT_FACTOR_CONFIG_NAME</h4>
<pre>static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.122">ACCEPT_FACTOR_CONFIG_NAME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.ACCEPT_FACTOR_CONFIG_NAME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="MIN_FACTOR_CONFIG_NAME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>MIN_FACTOR_CONFIG_NAME</h4>
<pre>static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.123">MIN_FACTOR_CONFIG_NAME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.MIN_FACTOR_CONFIG_NAME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="STRONG_REF_KEY">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>STRONG_REF_KEY</h4>
<pre>private static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.126">STRONG_REF_KEY</a></pre>
<div class="block">Use strong reference for offsetLock or not</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.STRONG_REF_KEY">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="STRONG_REF_DEFAULT">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>STRONG_REF_DEFAULT</h4>
<pre>private static final&nbsp;boolean <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.127">STRONG_REF_DEFAULT</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.STRONG_REF_DEFAULT">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_SINGLE_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_SINGLE_FACTOR</h4>
<pre>static final&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.130">DEFAULT_SINGLE_FACTOR</a></pre>
<div class="block">Priority buckets</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_SINGLE_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_MULTI_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_MULTI_FACTOR</h4>
<pre>static final&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.131">DEFAULT_MULTI_FACTOR</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_MULTI_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_MEMORY_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_MEMORY_FACTOR</h4>
<pre>static final&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.132">DEFAULT_MEMORY_FACTOR</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_MEMORY_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_MIN_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_MIN_FACTOR</h4>
<pre>static final&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.133">DEFAULT_MIN_FACTOR</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_MIN_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_EXTRA_FREE_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_EXTRA_FREE_FACTOR</h4>
<pre>private static final&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.135">DEFAULT_EXTRA_FREE_FACTOR</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_EXTRA_FREE_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_ACCEPT_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_ACCEPT_FACTOR</h4>
<pre>private static final&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.136">DEFAULT_ACCEPT_FACTOR</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_ACCEPT_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_FREE_ENTIRE_BLOCK_FACTOR">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_FREE_ENTIRE_BLOCK_FACTOR</h4>
<pre>private static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.139">DEFAULT_FREE_ENTIRE_BLOCK_FACTOR</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_FREE_ENTIRE_BLOCK_FACTOR">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="statThreadPeriod">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>statThreadPeriod</h4>
<pre>private static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.142">statThreadPeriod</a></pre>
<div class="block">Statistics thread</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.statThreadPeriod">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_WRITER_THREADS">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_WRITER_THREADS</h4>
<pre>static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.144">DEFAULT_WRITER_THREADS</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_WRITER_THREADS">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_WRITER_QUEUE_ITEMS">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_WRITER_QUEUE_ITEMS</h4>
<pre>static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.145">DEFAULT_WRITER_QUEUE_ITEMS</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_WRITER_QUEUE_ITEMS">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="ioEngine">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>ioEngine</h4>
<pre>final transient&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/IOEngine.html" title="interface in org.apache.hadoop.hbase.io.hfile.bucket">IOEngine</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.148">ioEngine</a></pre>
</li>
</ul>
<a name="ramCache">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>ramCache</h4>
<pre>final transient&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMCache.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMCache</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.151">ramCache</a></pre>
</li>
</ul>
<a name="backingMap">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>backingMap</h4>
<pre>transient&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>,<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&gt; <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.154">backingMap</a></pre>
</li>
</ul>
<a name="backingMapValidated">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>backingMapValidated</h4>
<pre>private&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicBoolean.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicBoolean</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.156">backingMapValidated</a></pre>
</li>
</ul>
<a name="fullyCachedFiles">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>fullyCachedFiles</h4>
<pre>final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="../../../../../../../org/apache/hadoop/hbase/util/Pair.html" title="class in org.apache.hadoop.hbase.util">Pair</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;&gt; <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.163">fullyCachedFiles</a></pre>
<div class="block">Map of hFile -> Region -> File size. This map is used to track all files completed prefetch,
together with the region those belong to and the total cached size for the
region.TestBlockEvictionOnRegionMovement</div>
</li>
</ul>
<a name="regionCachedSize">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>regionCachedSize</h4>
<pre>final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt; <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.168">regionCachedSize</a></pre>
<div class="block">Map of region -> total size of the region prefetched on this region server. This is the total
size of hFiles for this region prefetched on this region server</div>
</li>
</ul>
<a name="cachePersister">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cachePersister</h4>
<pre>private&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCachePersister.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCachePersister</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.170">cachePersister</a></pre>
</li>
</ul>
<a name="cacheEnabled">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheEnabled</h4>
<pre>private volatile&nbsp;boolean <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.176">cacheEnabled</a></pre>
<div class="block">Flag if the cache is enabled or not... We shut it off if there are IO errors for some time, so
that Bucket IO exceptions/errors don't bring down the HBase server.</div>
</li>
</ul>
<a name="writerQueues">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writerQueues</h4>
<pre>final transient&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/ArrayList.html?is-external=true" title="class or interface in java.util">ArrayList</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/BlockingQueue.html?is-external=true" title="class or interface in java.util.concurrent">BlockingQueue</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&gt; <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.185">writerQueues</a></pre>
<div class="block">A list of writer queues. We have a queue per <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.WriterThread.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketCache.WriterThread</code></a> we have running. In other
words, the work adding blocks to the BucketCache is divided up amongst the running
WriterThreads. Its done by taking hash of the cache key modulo queue count. WriterThread when
it runs takes whatever has been recently added and 'drains' the entries to the BucketCache. It
then updates the ramCache and backingMap accordingly.</div>
</li>
</ul>
<a name="writerThreads">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writerThreads</h4>
<pre>final transient&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.WriterThread.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.WriterThread</a>[] <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.186">writerThreads</a></pre>
</li>
</ul>
<a name="freeInProgress">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>freeInProgress</h4>
<pre>private volatile&nbsp;boolean <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.189">freeInProgress</a></pre>
<div class="block">Volatile boolean to track if free space is in process or not</div>
</li>
</ul>
<a name="freeSpaceLock">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>freeSpaceLock</h4>
<pre>private final transient&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/locks/Lock.html?is-external=true" title="class or interface in java.util.concurrent.locks">Lock</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.190">freeSpaceLock</a></pre>
</li>
</ul>
<a name="realCacheSize">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>realCacheSize</h4>
<pre>private final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/LongAdder.html?is-external=true" title="class or interface in java.util.concurrent.atomic">LongAdder</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.192">realCacheSize</a></pre>
</li>
</ul>
<a name="heapSize">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>heapSize</h4>
<pre>private final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/LongAdder.html?is-external=true" title="class or interface in java.util.concurrent.atomic">LongAdder</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.193">heapSize</a></pre>
</li>
</ul>
<a name="blockNumber">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>blockNumber</h4>
<pre>private final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/LongAdder.html?is-external=true" title="class or interface in java.util.concurrent.atomic">LongAdder</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.195">blockNumber</a></pre>
<div class="block">Current number of cached elements</div>
</li>
</ul>
<a name="accessCount">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>accessCount</h4>
<pre>private final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicLong.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicLong</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.198">accessCount</a></pre>
<div class="block">Cache access count (sequential ID)</div>
</li>
</ul>
<a name="DEFAULT_CACHE_WAIT_TIME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_CACHE_WAIT_TIME</h4>
<pre>private static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.200">DEFAULT_CACHE_WAIT_TIME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_CACHE_WAIT_TIME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="cacheStats">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheStats</h4>
<pre>private final&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCacheStats.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCacheStats</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.202">cacheStats</a></pre>
</li>
</ul>
<a name="persistencePath">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>persistencePath</h4>
<pre>private final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.203">persistencePath</a></pre>
</li>
</ul>
<a name="isCacheInconsistent">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isCacheInconsistent</h4>
<pre>static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicBoolean.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicBoolean</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.204">isCacheInconsistent</a></pre>
</li>
</ul>
<a name="cacheCapacity">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheCapacity</h4>
<pre>private final&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.205">cacheCapacity</a></pre>
</li>
</ul>
<a name="blockSize">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>blockSize</h4>
<pre>private final&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.207">blockSize</a></pre>
<div class="block">Approximate block size</div>
</li>
</ul>
<a name="ioErrorsTolerationDuration">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>ioErrorsTolerationDuration</h4>
<pre>private final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.210">ioErrorsTolerationDuration</a></pre>
<div class="block">Duration of IO errors tolerated before we disable cache, 1 min as default</div>
</li>
</ul>
<a name="DEFAULT_ERROR_TOLERATION_DURATION">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_ERROR_TOLERATION_DURATION</h4>
<pre>public static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.212">DEFAULT_ERROR_TOLERATION_DURATION</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_ERROR_TOLERATION_DURATION">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="ioErrorStartTime">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>ioErrorStartTime</h4>
<pre>private volatile&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.216">ioErrorStartTime</a></pre>
</li>
</ul>
<a name="offsetLock">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>offsetLock</h4>
<pre>final transient&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/util/IdReadWriteLock.html" title="class in org.apache.hadoop.hbase.util">IdReadWriteLock</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt; <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.223">offsetLock</a></pre>
<div class="block">A ReentrantReadWriteLock to lock on a particular block identified by offset. The purpose of
this is to avoid freeing the block which is being read.
<p></div>
</li>
</ul>
<a name="blocksByHFile">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>blocksByHFile</h4>
<pre><a href="https://docs.oracle.com/javase/8/docs/api/java/util/NavigableSet.html?is-external=true" title="class or interface in java.util">NavigableSet</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&gt; <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.225">blocksByHFile</a></pre>
</li>
</ul>
<a name="scheduleThreadPool">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>scheduleThreadPool</h4>
<pre>private final transient&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/ScheduledExecutorService.html?is-external=true" title="class or interface in java.util.concurrent">ScheduledExecutorService</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.229">scheduleThreadPool</a></pre>
<div class="block">Statistics thread schedule pool (for heavy debugging, could remove)</div>
</li>
</ul>
<a name="bucketAllocator">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bucketAllocator</h4>
<pre>private transient&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocator.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketAllocator</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.234">bucketAllocator</a></pre>
</li>
</ul>
<a name="acceptableFactor">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>acceptableFactor</h4>
<pre>private&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.237">acceptableFactor</a></pre>
<div class="block">Acceptable size of cache (no evictions if size < acceptable)</div>
</li>
</ul>
<a name="minFactor">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>minFactor</h4>
<pre>private&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.240">minFactor</a></pre>
<div class="block">Minimum threshold of cache (when evicting, evict until size < min)</div>
</li>
</ul>
<a name="extraFreeFactor">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>extraFreeFactor</h4>
<pre>private&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.246">extraFreeFactor</a></pre>
<div class="block">Free this floating point factor of extra blocks when evicting. For example free the number of
blocks requested * (1 + extraFreeFactor)</div>
</li>
</ul>
<a name="singleFactor">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>singleFactor</h4>
<pre>private&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.249">singleFactor</a></pre>
<div class="block">Single access bucket size</div>
</li>
</ul>
<a name="multiFactor">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>multiFactor</h4>
<pre>private&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.252">multiFactor</a></pre>
<div class="block">Multiple access bucket size</div>
</li>
</ul>
<a name="memoryFactor">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>memoryFactor</h4>
<pre>private&nbsp;float <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.255">memoryFactor</a></pre>
<div class="block">In-memory bucket size</div>
</li>
</ul>
<a name="bucketcachePersistInterval">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bucketcachePersistInterval</h4>
<pre>private&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.257">bucketcachePersistInterval</a></pre>
</li>
</ul>
<a name="FILE_VERIFY_ALGORITHM">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>FILE_VERIFY_ALGORITHM</h4>
<pre>private static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.259">FILE_VERIFY_ALGORITHM</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.FILE_VERIFY_ALGORITHM">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_FILE_VERIFY_ALGORITHM">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_FILE_VERIFY_ALGORITHM</h4>
<pre>private static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.261">DEFAULT_FILE_VERIFY_ALGORITHM</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_FILE_VERIFY_ALGORITHM">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="QUEUE_ADDITION_WAIT_TIME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>QUEUE_ADDITION_WAIT_TIME</h4>
<pre>private static final&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.263">QUEUE_ADDITION_WAIT_TIME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.QUEUE_ADDITION_WAIT_TIME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="DEFAULT_QUEUE_ADDITION_WAIT_TIME">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>DEFAULT_QUEUE_ADDITION_WAIT_TIME</h4>
<pre>private static final&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.265">DEFAULT_QUEUE_ADDITION_WAIT_TIME</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.DEFAULT_QUEUE_ADDITION_WAIT_TIME">Constant Field Values</a></dd>
</dl>
</li>
</ul>
<a name="queueAdditionWaitTime">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>queueAdditionWaitTime</h4>
<pre>private&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.266">queueAdditionWaitTime</a></pre>
</li>
</ul>
<a name="algorithm">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>algorithm</h4>
<pre>private&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.271">algorithm</a></pre>
<div class="block">Use <a href="https://docs.oracle.com/javase/8/docs/api/java/security/MessageDigest.html?is-external=true" title="class or interface in java.security"><code>MessageDigest</code></a> class's encryption algorithms to check persistent file
integrity, default algorithm is MD5</div>
</li>
</ul>
<a name="allocFailLogPrevTs">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>allocFailLogPrevTs</h4>
<pre>private&nbsp;long <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.274">allocFailLogPrevTs</a></pre>
</li>
</ul>
<a name="ALLOCATION_FAIL_LOG_TIME_PERIOD">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>ALLOCATION_FAIL_LOG_TIME_PERIOD</h4>
<pre>private static final&nbsp;int <a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.275">ALLOCATION_FAIL_LOG_TIME_PERIOD</a></pre>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../constant-values.html#org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.ALLOCATION_FAIL_LOG_TIME_PERIOD">Constant Field Values</a></dd>
</dl>
</li>
</ul>
</li>
</ul>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="BucketCache-java.lang.String-long-int-int:A-int-int-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>BucketCache</h4>
<pre>public&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.277">BucketCache</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioEngineName,
long&nbsp;capacity,
int&nbsp;blockSize,
int[]&nbsp;bucketSizes,
int&nbsp;writerThreadNum,
int&nbsp;writerQLen,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;persistencePath)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="BucketCache-java.lang.String-long-int-int:A-int-int-java.lang.String-int-org.apache.hadoop.conf.Configuration-">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>BucketCache</h4>
<pre>public&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.283">BucketCache</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioEngineName,
long&nbsp;capacity,
int&nbsp;blockSize,
int[]&nbsp;bucketSizes,
int&nbsp;writerThreadNum,
int&nbsp;writerQLen,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;persistencePath,
int&nbsp;ioErrorsTolerationDuration,
org.apache.hadoop.conf.Configuration&nbsp;conf)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="sanityCheckConfigs--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>sanityCheckConfigs</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.373">sanityCheckConfigs</a>()</pre>
</li>
</ul>
<a name="startWriterThreads--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>startWriterThreads</h4>
<pre>protected&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.397">startWriterThreads</a>()</pre>
<div class="block">Called by the constructor to start the writer threads. Used by tests that need to override
starting the threads.</div>
</li>
</ul>
<a name="startBucketCachePersisterThread--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>startBucketCachePersisterThread</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.403">startBucketCachePersisterThread</a>()</pre>
</li>
</ul>
<a name="isCacheEnabled--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isCacheEnabled</h4>
<pre>boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.410">isCacheEnabled</a>()</pre>
</li>
</ul>
<a name="getMaxSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMaxSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.415">getMaxSize</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getMaxSize--">BlockCache</a></code></span></div>
<div class="block">Returns the Max size of the block cache, in bytes.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getMaxSize--">getMaxSize</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>size of cache, in bytes</dd>
</dl>
</li>
</ul>
<a name="getIoEngine--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getIoEngine</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.419">getIoEngine</a>()</pre>
</li>
</ul>
<a name="getIOEngineFromName-java.lang.String-long-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getIOEngineFromName</h4>
<pre>private&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/IOEngine.html" title="interface in org.apache.hadoop.hbase.io.hfile.bucket">IOEngine</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.427">getIOEngineFromName</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioEngineName,
long&nbsp;capacity,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;persistencePath)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Get the IOEngine from the IO engine name</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the IOEngine</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="isCachePersistenceEnabled--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isCachePersistenceEnabled</h4>
<pre>public&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.454">isCachePersistenceEnabled</a>()</pre>
</li>
</ul>
<a name="cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheBlock</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.464">cacheBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;buf)</pre>
<div class="block">Cache the block with the specified name and buffer.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-">cacheBlock</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cacheKey</code> - block's cache key</dd>
<dd><code>buf</code> - block buffer</dd>
</dl>
</li>
</ul>
<a name="cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheBlock</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.475">cacheBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory)</pre>
<div class="block">Cache the block with the specified name and buffer.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-">cacheBlock</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cacheKey</code> - block's cache key</dd>
<dd><code>cachedItem</code> - block buffer</dd>
<dd><code>inMemory</code> - if block is in-memory</dd>
</dl>
</li>
</ul>
<a name="cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheBlock</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.486">cacheBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory,
boolean&nbsp;waitWhenCache)</pre>
<div class="block">Cache the block with the specified name and buffer.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#cacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">cacheBlock</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cacheKey</code> - block's cache key</dd>
<dd><code>cachedItem</code> - block buffer</dd>
<dd><code>inMemory</code> - if block is in-memory</dd>
<dd><code>waitWhenCache</code> - Whether to wait for the cache to be flushed mainly when BucketCache is
configured.</dd>
</dl>
</li>
</ul>
<a name="cacheBlockWithWait-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheBlockWithWait</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.498">cacheBlockWithWait</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory,
boolean&nbsp;wait)</pre>
<div class="block">Cache the block to ramCache</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cacheKey</code> - block's cache key</dd>
<dd><code>cachedItem</code> - block buffer</dd>
<dd><code>inMemory</code> - if block is in-memory</dd>
<dd><code>wait</code> - if true, blocking wait when queue is full</dd>
</dl>
</li>
</ul>
<a name="shouldReplaceExistingCacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>shouldReplaceExistingCacheBlock</h4>
<pre>protected&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.516">shouldReplaceExistingCacheBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;newBlock)</pre>
</li>
</ul>
<a name="cacheBlockWithWaitInternal-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-boolean-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>cacheBlockWithWaitInternal</h4>
<pre>protected&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.520">cacheBlockWithWaitInternal</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;cachedItem,
boolean&nbsp;inMemory,
boolean&nbsp;wait)</pre>
</li>
</ul>
<a name="getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBlock</h4>
<pre>public&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/Cacheable.html" title="interface in org.apache.hadoop.hbase.io.hfile">Cacheable</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.572">getBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key,
boolean&nbsp;caching,
boolean&nbsp;repeat,
boolean&nbsp;updateCacheMetrics)</pre>
<div class="block">Get the buffer of the block with the specified key.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-">getBlock</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - block's cache key</dd>
<dd><code>caching</code> - true if the caller caches blocks on cache misses</dd>
<dd><code>repeat</code> - Whether this is a repeat lookup for the same block</dd>
<dd><code>updateCacheMetrics</code> - Whether we should update cache metrics or not</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>buffer of specified cache key, or null if not in cache</dd>
</dl>
</li>
</ul>
<a name="blockEvicted-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-boolean-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>blockEvicted</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.638">blockEvicted</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry,
boolean&nbsp;decrementBlockNumber,
boolean&nbsp;evictedByEvictionProcess)</pre>
<div class="block">This method is invoked after the bucketEntry is removed from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a></div>
</li>
</ul>
<a name="fileNotFullyCached-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>fileNotFullyCached</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.656">fileNotFullyCached</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;hfileName)</pre>
</li>
</ul>
<a name="fileCacheCompleted-org.apache.hadoop.fs.Path-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>fileCacheCompleted</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.675">fileCacheCompleted</a>(org.apache.hadoop.fs.Path&nbsp;filePath,
long&nbsp;size)</pre>
</li>
</ul>
<a name="updateRegionCachedSize-org.apache.hadoop.fs.Path-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>updateRegionCachedSize</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.684">updateRegionCachedSize</a>(org.apache.hadoop.fs.Path&nbsp;filePath,
long&nbsp;cachedSize)</pre>
</li>
</ul>
<a name="freeBucketEntry-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>freeBucketEntry</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.696">freeBucketEntry</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</pre>
<div class="block">Free the {<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> actually,which could only be invoked when the
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#refCnt"><code>BucketEntry.refCnt</code></a> becoming 0.</div>
</li>
</ul>
<a name="evictBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>evictBlock</h4>
<pre>public&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.718">evictBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey)</pre>
<div class="block">Try to evict the block from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile"><code>BlockCache</code></a> by force. We'll call this in few cases:<br>
1. Close an HFile, and clear all cached blocks. <br>
2. Call <a href="../../../../../../../org/apache/hadoop/hbase/client/Admin.html#clearBlockCache-org.apache.hadoop.hbase.TableName-"><code>Admin.clearBlockCache(TableName)</code></a> to clear all blocks for a given table.<br>
<p>
Firstly, we'll try to remove the block from RAMCache,and then try to evict from backingMap.
Here we evict the block from backingMap immediately, but only free the reference from bucket
cache by calling <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#markedAsEvicted"><code>BucketEntry.markedAsEvicted</code></a>. If there're still some RPC referring this
block, block can only be de-allocated when all of them release the block.
<p>
NOTICE: we need to grab the write offset lock firstly before releasing the reference from
bucket cache. if we don't, we may read an <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> with refCnt = 0 when
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-"><code>getBlock(BlockCacheKey, boolean, boolean, boolean)</code></a>, it's a memory leak.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#evictBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">evictBlock</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cacheKey</code> - Block to evict</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true to indicate whether we've evicted successfully or not.</dd>
</dl>
</li>
</ul>
<a name="doEvictBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>doEvictBlock</h4>
<pre>private&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.731">doEvictBlock</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry,
boolean&nbsp;evictedByEvictionProcess)</pre>
<div class="block">Evict the <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> and <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a> and
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ramCache"><code>ramCache</code></a>. <br/>
NOTE:When Evict from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a>,only the matched <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> and
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> could be removed.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>cacheKey</code> - <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> to evict.</dd>
<dd><code>bucketEntry</code> - <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> matched <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> to evict.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true to indicate whether we've evicted successfully or not.</dd>
</dl>
</li>
</ul>
<a name="createRecycler-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createRecycler</h4>
<pre>private&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/ByteBuffAllocator.Recycler.html" title="interface in org.apache.hadoop.hbase.io">ByteBuffAllocator.Recycler</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.773">createRecycler</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</pre>
<div class="block"><pre>
Create the <a href="../../../../../../../org/apache/hadoop/hbase/io/ByteBuffAllocator.Recycler.html" title="interface in org.apache.hadoop.hbase.io"><code>ByteBuffAllocator.Recycler</code></a> for <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#refCnt"><code>BucketEntry.refCnt</code></a>,which would be used as
<a href="../../../../../../../org/apache/hadoop/hbase/nio/RefCnt.html#recycler"><code>RefCnt.recycler</code></a> of <code>HFileBlock#buf</code> returned from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-"><code>getBlock(org.apache.hadoop.hbase.io.hfile.BlockCacheKey, boolean, boolean, boolean)</code></a>.
NOTE: for <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#getBlock-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-boolean-boolean-boolean-"><code>getBlock(org.apache.hadoop.hbase.io.hfile.BlockCacheKey, boolean, boolean, boolean)</code></a>,the <a href="../../../../../../../org/apache/hadoop/hbase/nio/RefCnt.html#recycler"><code>RefCnt.recycler</code></a> of <code>HFileBlock#buf</code>
from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a> and <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ramCache"><code>ramCache</code></a> are different:
1.For <a href="../../../../../../../org/apache/hadoop/hbase/nio/RefCnt.html#recycler"><code>RefCnt.recycler</code></a> of <code>HFileBlock#buf</code> from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a>,
it is the return value of current <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#createRecycler-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-"><code>createRecycler(org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry)</code></a> method.
2.For <a href="../../../../../../../org/apache/hadoop/hbase/nio/RefCnt.html#recycler"><code>RefCnt.recycler</code></a> of <code>HFileBlock#buf</code> from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#ramCache"><code>ramCache</code></a>,
it is <a href="../../../../../../../org/apache/hadoop/hbase/io/ByteBuffAllocator.html#putbackBuffer-java.nio.ByteBuffer-"><code>ByteBuffAllocator.putbackBuffer(java.nio.ByteBuffer)</code></a>.
</pre></div>
</li>
</ul>
<a name="evictBlockIfNoRpcReferenced-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>evictBlockIfNoRpcReferenced</h4>
<pre>public&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.783">evictBlockIfNoRpcReferenced</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;blockCacheKey)</pre>
<div class="block">NOTE: This method is only for test.</div>
</li>
</ul>
<a name="evictBucketEntryIfNoRpcReferenced-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>evictBucketEntryIfNoRpcReferenced</h4>
<pre>boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.800">evictBucketEntryIfNoRpcReferenced</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;blockCacheKey,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</pre>
<div class="block">Evict <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> and its corresponding <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> only if
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html#isRpcRef--"><code>BucketEntry.isRpcRef()</code></a> is false. <br/>
NOTE:When evict from <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#backingMap"><code>backingMap</code></a>,only the matched <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> and
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> could be removed.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>blockCacheKey</code> - <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> to evict.</dd>
<dd><code>bucketEntry</code> - <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><code>BucketEntry</code></a> matched <a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile"><code>BlockCacheKey</code></a> to evict.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>true to indicate whether we've evicted successfully or not.</dd>
</dl>
</li>
</ul>
<a name="removeFromRamCache-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>removeFromRamCache</h4>
<pre>protected&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.807">removeFromRamCache</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey)</pre>
</li>
</ul>
<a name="isCacheInconsistent--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isCacheInconsistent</h4>
<pre>public&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.816">isCacheInconsistent</a>()</pre>
</li>
</ul>
<a name="setCacheInconsistent-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setCacheInconsistent</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.820">setCacheInconsistent</a>(boolean&nbsp;setCacheInconsistent)</pre>
</li>
</ul>
<a name="logStats--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>logStats</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.842">logStats</a>()</pre>
</li>
</ul>
<a name="getRealCacheSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRealCacheSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.870">getRealCacheSize</a>()</pre>
</li>
</ul>
<a name="acceptableSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>acceptableSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.874">acceptableSize</a>()</pre>
</li>
</ul>
<a name="getPartitionSize-float-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getPartitionSize</h4>
<pre>long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.878">getPartitionSize</a>(float&nbsp;partitionFactor)</pre>
</li>
</ul>
<a name="bucketSizesAboveThresholdCount-float-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>bucketSizesAboveThresholdCount</h4>
<pre>private&nbsp;int&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.885">bucketSizesAboveThresholdCount</a>(float&nbsp;minFactor)</pre>
<div class="block">Return the count of bucketSizeinfos still need free space</div>
</li>
</ul>
<a name="freeEntireBuckets-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>freeEntireBuckets</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.905">freeEntireBuckets</a>(int&nbsp;completelyFreeBucketsNeeded)</pre>
<div class="block">This method will find the buckets that are minimally occupied and are not reference counted and
will free them completely without any constraint on the access times of the elements, and as a
process will completely free at most the number of buckets passed, sometimes it might not due
to changing refCounts</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>completelyFreeBucketsNeeded</code> - number of buckets to free</dd>
</dl>
</li>
</ul>
<a name="freeSpace-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>freeSpace</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.931">freeSpace</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;why)</pre>
<div class="block">Free the space if the used size reaches acceptableSize() or one size block couldn't be
allocated. When freeing the space, we use the LRU algorithm and ensure there must be some
blocks evicted</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>why</code> - Why we are being called</dd>
</dl>
</li>
</ul>
<a name="putIntoBackingMap-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.bucket.BucketEntry-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>putIntoBackingMap</h4>
<pre>protected&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1121">putIntoBackingMap</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&nbsp;bucketEntry)</pre>
<div class="block">Put the new bucket entry into backingMap. Notice that we are allowed to replace the existing
cache with a new block for the same cache key. there's a corner case: one thread cache a block
in ramCache, copy to io-engine and add a bucket entry to backingMap. Caching another new block
with the same cache key do the same thing for the same cache key, so if not evict the previous
bucket entry, then memory leak happen because the previous bucketEntry is gone but the
bucketAllocator do not free its memory.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - Block cache key</dd>
<dd><code>bucketEntry</code> - Bucket entry to put into backingMap.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheUtil.html#shouldReplaceExistingCacheBlock-org.apache.hadoop.hbase.io.hfile.BlockCache-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-org.apache.hadoop.hbase.io.hfile.Cacheable-"><code>BlockCacheUtil.shouldReplaceExistingCacheBlock(BlockCache blockCache,BlockCacheKey
cacheKey, Cacheable newBlock)</code></a></dd>
</dl>
</li>
</ul>
<a name="getAllocationFailWarningMessage-org.apache.hadoop.hbase.io.hfile.bucket.BucketAllocatorException-org.apache.hadoop.hbase.io.hfile.bucket.BucketCache.RAMQueueEntry-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAllocationFailWarningMessage</h4>
<pre>private static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1139">getAllocationFailWarningMessage</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocatorException.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketAllocatorException</a>&nbsp;fle,
<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&nbsp;re)</pre>
<div class="block">Prepare and return a warning message for Bucket Allocator Exception</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>fle</code> - The exception</dd>
<dd><code>re</code> - The RAMQueueEntry for which the exception was thrown.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>A warning message created from the input RAMQueueEntry object.</dd>
</dl>
</li>
</ul>
<a name="doDrain-java.util.List-java.nio.ByteBuffer-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>doDrain</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1181">doDrain</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;entries,
<a href="https://docs.oracle.com/javase/8/docs/api/java/nio/ByteBuffer.html?is-external=true" title="class or interface in java.nio">ByteBuffer</a>&nbsp;metaBuff)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></pre>
<div class="block">Flush the entries in ramCache to IOEngine and add bucket entry to backingMap. Process all that
are passed in even if failure being sure to remove from ramCache else we'll never undo the
references and we'll OOME.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>entries</code> - Presumes list passed in here will be processed by this invocation only. No
interference expected.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></code></dd>
</dl>
</li>
</ul>
<a name="getRAMQueueEntries-java.util.concurrent.BlockingQueue-java.util.List-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRAMQueueEntries</h4>
<pre>static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1305">getRAMQueueEntries</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/BlockingQueue.html?is-external=true" title="class or interface in java.util.concurrent">BlockingQueue</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;q,
<a href="https://docs.oracle.com/javase/8/docs/api/java/util/List.html?is-external=true" title="class or interface in java.util">List</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.RAMQueueEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache.RAMQueueEntry</a>&gt;&nbsp;receptacle)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></pre>
<div class="block">Blocks until elements available in <code>q</code> then tries to grab as many as possible before
returning.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>receptacle</code> - Where to stash the elements taken from queue. We clear before we use it just
in case.</dd>
<dd><code>q</code> - The queue to take from.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>receptacle</code> laden with elements taken from the queue or empty if none found.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></code></dd>
</dl>
</li>
</ul>
<a name="persistToFile--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>persistToFile</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1320">persistToFile</a>()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#retrieveFromFile-int:A-"><code>retrieveFromFile(int[])</code></a></dd>
</dl>
</li>
</ul>
<a name="isCachePersistent--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isCachePersistent</h4>
<pre>public&nbsp;boolean&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1342">isCachePersistent</a>()</pre>
</li>
</ul>
<a name="getRegionCachedInfo--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRegionCachedInfo</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1347">getRegionCachedInfo</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getRegionCachedInfo--">BlockCache</a></code></span></div>
<div class="block">Returns an Optional containing a map of regions and the percentage of how much of it has been
cached so far.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getRegionCachedInfo--">getRegionCachedInfo</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>empty optional if this method is not supported, otherwise the returned optional
contains a map of current regions caching percentage.</dd>
</dl>
</li>
</ul>
<a name="retrieveFromFile-int:A-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>retrieveFromFile</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1354">retrieveFromFile</a>(int[]&nbsp;bucketSizes)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#persistToFile--"><code>persistToFile()</code></a></dd>
</dl>
</li>
</ul>
<a name="updateRegionSizeMapWhileRetrievingFromFile--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>updateRegionSizeMapWhileRetrievingFromFile</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1388">updateRegionSizeMapWhileRetrievingFromFile</a>()</pre>
</li>
</ul>
<a name="dumpPrefetchList--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>dumpPrefetchList</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1404">dumpPrefetchList</a>()</pre>
</li>
</ul>
<a name="deleteFileOnClose-java.io.File-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>deleteFileOnClose</h4>
<pre>private&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/io/FileInputStream.html?is-external=true" title="class or interface in java.io">FileInputStream</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1428">deleteFileOnClose</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a>&nbsp;file)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<div class="block">Create an input stream that deletes the file after reading it. Use in try-with-resources to
avoid this pattern where an exception thrown from a finally block may mask earlier exceptions:
<pre>
File f = ...
try (FileInputStream fis = new FileInputStream(f)) {
// use the input stream
} finally {
if (!f.delete()) throw new IOException("failed to delete");
}
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>file</code> - the file to read and delete</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a FileInputStream for the given file</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code> - if there is a problem creating the stream</dd>
</dl>
</li>
</ul>
<a name="verifyCapacityAndClasses-long-java.lang.String-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>verifyCapacityAndClasses</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1455">verifyCapacityAndClasses</a>(long&nbsp;capacitySize,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;ioclass,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;mapclass)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="parsePB-org.apache.hadoop.hbase.shaded.protobuf.generated.BucketCacheProtos.BucketCacheEntry-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>parsePB</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1471">parsePB</a>(org.apache.hadoop.hbase.shaded.protobuf.generated.BucketCacheProtos.BucketCacheEntry&nbsp;proto)
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd>
</dl>
</li>
</ul>
<a name="checkIOErrorIsTolerated--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>checkIOErrorIsTolerated</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1529">checkIOErrorIsTolerated</a>()</pre>
<div class="block">Check whether we tolerate IO error this time. If the duration of IOEngine throwing errors
exceeds ioErrorsDurationTimeTolerated, we will disable the cache</div>
</li>
</ul>
<a name="disableCache--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>disableCache</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1547">disableCache</a>()</pre>
<div class="block">Used to shut down the cache -or- turn it off in the case of something broken.</div>
</li>
</ul>
<a name="join--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>join</h4>
<pre>private&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1565">join</a>()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></pre>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></code></dd>
</dl>
</li>
</ul>
<a name="shutdown--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>shutdown</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1571">shutdown</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#shutdown--">BlockCache</a></code></span></div>
<div class="block">Shutdown the cache.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#shutdown--">shutdown</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
</dl>
</li>
</ul>
<a name="finalize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>finalize</h4>
<pre>protected&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1599">finalize</a>()</pre>
<div class="block">Needed mostly for UTs that might run in the same VM and create different BucketCache instances
on different UT methods.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#finalize--" title="class or interface in java.lang">finalize</a></code>&nbsp;in class&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></code></dd>
</dl>
</li>
</ul>
<a name="getStats--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getStats</h4>
<pre>public&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CacheStats.html" title="class in org.apache.hadoop.hbase.io.hfile">CacheStats</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1606">getStats</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getStats--">BlockCache</a></code></span></div>
<div class="block">Get the statistics for this block cache.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getStats--">getStats</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
</dl>
</li>
</ul>
<a name="getAllocator--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAllocator</h4>
<pre>public&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocator.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketAllocator</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1610">getAllocator</a>()</pre>
</li>
</ul>
<a name="heapSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>heapSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1615">heapSize</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/HeapSize.html#heapSize--">HeapSize</a></code></span></div>
<div class="block">Return the approximate 'exclusive deep size' of implementing object. Includes count of payload
and hosting object sizings.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/HeapSize.html#heapSize--">heapSize</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/HeapSize.html" title="interface in org.apache.hadoop.hbase.io">HeapSize</a></code></dd>
</dl>
</li>
</ul>
<a name="size--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>size</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1620">size</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#size--">BlockCache</a></code></span></div>
<div class="block">Returns the total size of the block cache, in bytes.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#size--">size</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>size of cache, in bytes</dd>
</dl>
</li>
</ul>
<a name="getCurrentDataSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getCurrentDataSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1625">getCurrentDataSize</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getCurrentDataSize--">BlockCache</a></code></span></div>
<div class="block">Returns the occupied size of data blocks, in bytes.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getCurrentDataSize--">getCurrentDataSize</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>occupied space in cache, in bytes</dd>
</dl>
</li>
</ul>
<a name="getFreeSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getFreeSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1630">getFreeSize</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getFreeSize--">BlockCache</a></code></span></div>
<div class="block">Returns the free size of the block cache, in bytes.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getFreeSize--">getFreeSize</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>free space in cache, in bytes</dd>
</dl>
</li>
</ul>
<a name="getBlockCount--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBlockCount</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1635">getBlockCount</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlockCount--">BlockCache</a></code></span></div>
<div class="block">Returns the number of blocks currently cached in the block cache.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlockCount--">getBlockCount</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>number of blocks in the cache</dd>
</dl>
</li>
</ul>
<a name="getDataBlockCount--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDataBlockCount</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1640">getDataBlockCount</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getDataBlockCount--">BlockCache</a></code></span></div>
<div class="block">Returns the number of data blocks currently cached in the block cache.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getDataBlockCount--">getDataBlockCount</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>number of blocks in the cache</dd>
</dl>
</li>
</ul>
<a name="getCurrentSize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getCurrentSize</h4>
<pre>public&nbsp;long&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1645">getCurrentSize</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getCurrentSize--">BlockCache</a></code></span></div>
<div class="block">Returns the occupied size of the block cache, in bytes.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getCurrentSize--">getCurrentSize</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>occupied space in cache, in bytes</dd>
</dl>
</li>
</ul>
<a name="getAlgorithm--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAlgorithm</h4>
<pre>protected&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1649">getAlgorithm</a>()</pre>
</li>
</ul>
<a name="evictBlocksByHfileName-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>evictBlocksByHfileName</h4>
<pre>public&nbsp;int&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1660">evictBlocksByHfileName</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;hfileName)</pre>
<div class="block">Evicts all blocks for a specific HFile.
<p>
This is used for evict-on-close to remove all blocks of a specific HFile.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#evictBlocksByHfileName-java.lang.String-">evictBlocksByHfileName</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the number of blocks evicted</dd>
</dl>
</li>
</ul>
<a name="getAllCacheKeysForFile-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAllCacheKeysForFile</h4>
<pre>private&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Set.html?is-external=true" title="class or interface in java.util">Set</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1672">getAllCacheKeysForFile</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;hfileName)</pre>
</li>
</ul>
<a name="stopWriterThreads--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>stopWriterThreads</h4>
<pre>void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1822">stopWriterThreads</a>()
throws <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></pre>
<div class="block">Only used in test</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/InterruptedException.html?is-external=true" title="class or interface in java.lang">InterruptedException</a></code></dd>
</dl>
</li>
</ul>
<a name="iterator--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>iterator</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util">Iterator</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CachedBlock.html" title="interface in org.apache.hadoop.hbase.io.hfile">CachedBlock</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1831">iterator</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#iterator--">BlockCache</a></code></span></div>
<div class="block">Returns Iterator over the blocks in the cache.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#iterator--" title="class or interface in java.lang">iterator</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang">Iterable</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CachedBlock.html" title="interface in org.apache.hadoop.hbase.io.hfile">CachedBlock</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#iterator--">iterator</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
</dl>
</li>
</ul>
<a name="getBlockCaches--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBlockCaches</h4>
<pre>public&nbsp;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a>[]&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1921">getBlockCaches</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlockCaches--">BlockCache</a></code></span></div>
<div class="block">Returns The list of sub blockcaches that make up this one; returns null if no sub caches.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlockCaches--">getBlockCaches</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
</dl>
</li>
</ul>
<a name="getRpcRefCount-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRpcRefCount</h4>
<pre>public&nbsp;int&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1925">getRpcRefCount</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;cacheKey)</pre>
</li>
</ul>
<a name="getAcceptableFactor--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAcceptableFactor</h4>
<pre>float&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1933">getAcceptableFactor</a>()</pre>
</li>
</ul>
<a name="getMinFactor--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMinFactor</h4>
<pre>float&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1937">getMinFactor</a>()</pre>
</li>
</ul>
<a name="getExtraFreeFactor--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getExtraFreeFactor</h4>
<pre>float&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1941">getExtraFreeFactor</a>()</pre>
</li>
</ul>
<a name="getSingleFactor--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getSingleFactor</h4>
<pre>float&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1945">getSingleFactor</a>()</pre>
</li>
</ul>
<a name="getMultiFactor--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMultiFactor</h4>
<pre>float&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1949">getMultiFactor</a>()</pre>
</li>
</ul>
<a name="getMemoryFactor--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getMemoryFactor</h4>
<pre>float&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1953">getMemoryFactor</a>()</pre>
</li>
</ul>
<a name="getPersistencePath--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getPersistencePath</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.1957">getPersistencePath</a>()</pre>
</li>
</ul>
<a name="getBackingMap--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBackingMap</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>,<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketEntry.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketEntry</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2044">getBackingMap</a>()</pre>
</li>
</ul>
<a name="getBackingMapValidated--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBackingMapValidated</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/atomic/AtomicBoolean.html?is-external=true" title="class or interface in java.util.concurrent.atomic">AtomicBoolean</a>&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2048">getBackingMapValidated</a>()</pre>
</li>
</ul>
<a name="getFullyCachedFiles--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getFullyCachedFiles</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true" title="class or interface in java.util">Map</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="../../../../../../../org/apache/hadoop/hbase/util/Pair.html" title="class in org.apache.hadoop.hbase.util">Pair</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>,<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Long.html?is-external=true" title="class or interface in java.lang">Long</a>&gt;&gt;&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2053">getFullyCachedFiles</a>()</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getFullyCachedFiles--">BlockCache</a></code></span></div>
<div class="block">Returns an Optional containing the map of files that have been fully cached (all its blocks are
present in the cache. This method may not be overridden by all implementing classes. In such
cases, the returned Optional will be empty.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getFullyCachedFiles--">getFullyCachedFiles</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>empty optional if this method is not supported, otherwise the returned optional
contains a map of all files that have been fully cached.</dd>
</dl>
</li>
</ul>
<a name="getBucketCacheFromCacheConfig-org.apache.hadoop.hbase.io.hfile.CacheConfig-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBucketCacheFromCacheConfig</h4>
<pre>public static&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket">BucketCache</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2057">getBucketCacheFromCacheConfig</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/CacheConfig.html" title="class in org.apache.hadoop.hbase.io.hfile">CacheConfig</a>&nbsp;cacheConf)</pre>
</li>
</ul>
<a name="notifyFileCachingCompleted-org.apache.hadoop.fs.Path-int-int-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>notifyFileCachingCompleted</h4>
<pre>public&nbsp;void&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2073">notifyFileCachingCompleted</a>(org.apache.hadoop.fs.Path&nbsp;fileName,
int&nbsp;totalBlockCount,
int&nbsp;dataBlockCount,
long&nbsp;size)</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#notifyFileCachingCompleted-org.apache.hadoop.fs.Path-int-int-long-">BlockCache</a></code></span></div>
<div class="block">Notifies the cache implementation that the given file has been fully cached (all its blocks
made into the cache).</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#notifyFileCachingCompleted-org.apache.hadoop.fs.Path-int-int-long-">notifyFileCachingCompleted</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>fileName</code> - the file that has been completely cached.</dd>
<dd><code>totalBlockCount</code> - the total of blocks cached for this file.</dd>
<dd><code>dataBlockCount</code> - number of DATA block type cached.</dd>
<dd><code>size</code> - the size, in bytes, cached.</dd>
</dl>
</li>
</ul>
<a name="blockFitsIntoTheCache-org.apache.hadoop.hbase.io.hfile.HFileBlock-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>blockFitsIntoTheCache</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2146">blockFitsIntoTheCache</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/HFileBlock.html" title="class in org.apache.hadoop.hbase.io.hfile">HFileBlock</a>&nbsp;block)</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#blockFitsIntoTheCache-org.apache.hadoop.hbase.io.hfile.HFileBlock-">BlockCache</a></code></span></div>
<div class="block">Checks whether there's enough space left in the cache to accommodate the passed block. This
method may not be overridden by all implementing classes. In such cases, the returned Optional
will be empty. For subclasses implementing this logic, the returned Optional would contain the
boolean value reflecting if the passed block fits into the remaining cache space available.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#blockFitsIntoTheCache-org.apache.hadoop.hbase.io.hfile.HFileBlock-">blockFitsIntoTheCache</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>block</code> - the block we want to check if fits into the cache.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>empty optional if this method is not supported, otherwise the returned optional
contains the boolean value informing if the block fits into the cache available space.</dd>
</dl>
</li>
</ul>
<a name="shouldCacheFile-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>shouldCacheFile</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2153">shouldCacheFile</a>(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;fileName)</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#shouldCacheFile-java.lang.String-">BlockCache</a></code></span></div>
<div class="block">Checks whether blocks for the passed file should be cached or not. This method may not be
overridden by all implementing classes. In such cases, the returned Optional will be empty. For
subclasses implementing this logic, the returned Optional would contain the boolean value
reflecting if the passed file should indeed be cached.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#shouldCacheFile-java.lang.String-">shouldCacheFile</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>fileName</code> - to check if it should be cached.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>empty optional if this method is not supported, otherwise the returned optional
contains the boolean value informing if the file should be cached.</dd>
</dl>
</li>
</ul>
<a name="isAlreadyCached-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isAlreadyCached</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2159">isAlreadyCached</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key)</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#isAlreadyCached-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">BlockCache</a></code></span></div>
<div class="block">Checks whether the block for the passed key is already cached. This method may not be
overridden by all implementing classes. In such cases, the returned Optional will be empty. For
subclasses implementing this logic, the returned Optional would contain the boolean value
reflecting if the block for the passed key is already cached or not.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#isAlreadyCached-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">isAlreadyCached</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - for the block we want to check if it's already in the cache.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>empty optional if this method is not supported, otherwise the returned optional
contains the boolean value informing if the block is already cached.</dd>
</dl>
</li>
</ul>
<a name="getBlockSize-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getBlockSize</h4>
<pre>public&nbsp;<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Optional.html?is-external=true" title="class or interface in java.util">Optional</a>&lt;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang">Integer</a>&gt;&nbsp;<a href="../../../../../../../src-html/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html#line.2164">getBlockSize</a>(<a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCacheKey.html" title="class in org.apache.hadoop.hbase.io.hfile">BlockCacheKey</a>&nbsp;key)</pre>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlockSize-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">BlockCache</a></code></span></div>
<div class="block">Returns an Optional containing the size of the block related to the passed key. If the block is
not in the cache, returned optional will be empty. Also, this method may not be overridden by
all implementing classes. In such cases, the returned Optional will be empty.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html#getBlockSize-org.apache.hadoop.hbase.io.hfile.BlockCacheKey-">getBlockSize</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/BlockCache.html" title="interface in org.apache.hadoop.hbase.io.hfile">BlockCache</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>key</code> - for the block we want to check if it's already in the cache.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>empty optional if this method is not supported, otherwise the returned optional
contains the boolean value informing if the block is already cached.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/BucketCache.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketAllocatorException.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li><a href="../../../../../../../org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.BucketEntryGroup.html" title="class in org.apache.hadoop.hbase.io.hfile.bucket"><span class="typeNameLink">Next&nbsp;Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../../../index.html?org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.html" target="_top">Frames</a></li>
<li><a href="BucketCache.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li><a href="#nested.class.summary">Nested</a>&nbsp;|&nbsp;</li>
<li><a href="#field.summary">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li><a href="#field.detail">Field</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &#169; 2007&#x2013;2020 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
</body>
</html>