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

ryan rawson commented on HBASE-1460:
------------------------------------

HFile synchronizes block retrieval internally.  

The sync is on the block index object, thus if 2 threads are looking to read 
the same block they will queue up on each other, one thread will do the work of 
loading, and the other will get the benefit from reading it from cache.  

So dont worry about syncing, we wont end up with double work.

I'm not sure HFile has the knowledge that it's opening an 'in-memory column 
family' - yet.. Obviously we'll have to fix this.

Thanks for improving our data structures.

> Concurrent LRU Block Cache
> --------------------------
>
>                 Key: HBASE-1460
>                 URL: https://issues.apache.org/jira/browse/HBASE-1460
>             Project: Hadoop HBase
>          Issue Type: Improvement
>          Components: io
>            Reporter: Jonathan Gray
>            Assignee: Jonathan Gray
>             Fix For: 0.20.0
>
>         Attachments: HBASE-1460-v1.patch
>
>
> The LRU-based block cache that will be committed in HBASE-1192 is thread-safe 
> but contains a big lock on the hash map.  Under high load, the block cache 
> will be hit very heavily from a number of threads, so it needs to be built to 
> handle massive concurrency.
> This issue aims to implement a new block cache with LRU eviction, but backed 
> by a ConcurrentHashMap and a separate eviction thread.  Influence will be 
> drawn from Solr's ConcurrentLRUCache, however there are major differences 
> because solr treats all cached elements as equal size whereas we are 
> dependent on our HeapSize interface with realistic (though approximate) heap 
> usage.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to