[
https://issues.apache.org/jira/browse/HBASE-20789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16525381#comment-16525381
]
Zach York commented on HBASE-20789:
-----------------------------------
[~openinx] Ah... I see that putIfAbsent now. I wonder why my testing didn't
uncover that (I ran it many times. I must have just gotten lucky :) )
[~Apache9] caching an already cached block was present long before HBASE-20447
(see [2]). It seems that to fix your memory leak case we need to add locking on
the key.
Does this need to be a putIfAbsent? What is the harm in replacing the key if it
is in the ramCache and hasn't been persisted yet?
[2]
[https://github.com/apache/hbase/blob/master/hbase-server/src/main/java/org/apache/hadoop/hbase/io/hfile/bucket/BucketCache.java#L440]
> TestBucketCache#testCacheBlockNextBlockMetadataMissing is flaky
> ---------------------------------------------------------------
>
> Key: HBASE-20789
> URL: https://issues.apache.org/jira/browse/HBASE-20789
> Project: HBase
> Issue Type: Bug
> Reporter: Zheng Hu
> Assignee: Zheng Hu
> Priority: Major
> Attachments: bucket-33718.out
>
>
> The UT failed frequently in our internal branch-2... Will dig into the UT.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)