HBASE-22363 Remove hardcoded number of read cache block buckets
Signed-off-by: Peter Somogyi <psomogyi@apache.org>
This commit is contained in:
parent
d08463e683
commit
ebc1fab882
|
@ -685,7 +685,7 @@ public class LruBlockCache implements ResizableBlockCache, HeapSize {
|
||||||
bucketQueue.add(bucketMulti);
|
bucketQueue.add(bucketMulti);
|
||||||
bucketQueue.add(bucketMemory);
|
bucketQueue.add(bucketMemory);
|
||||||
|
|
||||||
int remainingBuckets = 3;
|
int remainingBuckets = bucketQueue.size();
|
||||||
|
|
||||||
BlockBucket bucket;
|
BlockBucket bucket;
|
||||||
while((bucket = bucketQueue.poll()) != null) {
|
while((bucket = bucketQueue.poll()) != null) {
|
||||||
|
|
|
@ -764,7 +764,7 @@ public class BucketCache implements BlockCache, HeapSize {
|
||||||
bucketQueue.add(bucketMulti);
|
bucketQueue.add(bucketMulti);
|
||||||
bucketQueue.add(bucketMemory);
|
bucketQueue.add(bucketMemory);
|
||||||
|
|
||||||
int remainingBuckets = 3;
|
int remainingBuckets = bucketQueue.size();
|
||||||
long bytesFreed = 0;
|
long bytesFreed = 0;
|
||||||
|
|
||||||
BucketEntryGroup bucketGroup;
|
BucketEntryGroup bucketGroup;
|
||||||
|
|
Loading…
Reference in New Issue