hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Anoop Sam John (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-16651) LRUBlockCache#returnBlock should try return block to Victim Handler L2 cache.
Date Mon, 19 Sep 2016 10:00:26 GMT

    [ https://issues.apache.org/jira/browse/HBASE-16651?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15502932#comment-15502932
] 

Anoop Sam John commented on HBASE-16651:
----------------------------------------

bq. it was told that going forward the config of having combinedMode= false will be removed
Where is that comment/discussion?
Ya as per the cur code, we need this return to victimHandler also.
bq. Hope in our code (read path) we don't assume any where that since we get a block from
L1 it can be surely treated as a EXCLUSIVE mode block?
What is the issue even if that is assumed?  The returnBlock call will always happen.  Now
after this patch, the call come to L1 cache and it passed to L2 victim cache.  There we have
the SHARED mode check before deciding whether to decr a counter.
bq.One place to check is that prefetch executore in Storefile open where the blocks are read
and we don't release the blocks. May be we are handling correctly
The getBlocks calls in prefetch executor is doing the return.
{code}
HFileBlock block = readBlock(offset, onDiskSize, true, false, false, false,
                  null, null);
              // Need not update the current block. Ideally here the readBlock won't find
the
              // block in cache. We call this readBlock so that block data is read from FS
and
              // cached in BC. So there is no reference count increment that happens here.
              // The return will ideally be a noop because the block is not of MemoryType
SHARED.
              returnBlock(block);
{code}

> LRUBlockCache#returnBlock should try return block to Victim Handler L2 cache.
> -----------------------------------------------------------------------------
>
>                 Key: HBASE-16651
>                 URL: https://issues.apache.org/jira/browse/HBASE-16651
>             Project: HBase
>          Issue Type: Sub-task
>          Components: regionserver, Scanners
>    Affects Versions: 2.0.0
>            Reporter: Anoop Sam John
>            Assignee: Anoop Sam John
>             Fix For: 2.0.0
>
>         Attachments: HBASE-16651.patch
>
>
> In case of L1 and L2 cache usage with combinedMode = false, L2 is used as a victim handler
cache for L1 cache.  When a getBlock() request comes, L1 will see if block is in it and if
not it will try to provide the block from L2 cache. In such a case, the return block must
return the block to L2 cache and count down the ref count for the block.  But right now we
just ignore the returnBlock call in LRUCache



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message