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

Branimir Lambov commented on CASSANDRA-11452:
---------------------------------------------

bq. My plan is to iterate on your random walk.

This solution appears best to me too. I take it you don't want me to review the 
[hash test 
patch|https://github.com/ben-manes/caffeine/commit/22ce6339ec91fd7eadfb462fcb176aac69aeb47f]
 any more?

bq. I still think that the victim chosen should be by the random walk and I 
haven't grokked your reason not to.

I'll try paraphrasing once more:

Choosing the victim by a random walk means that we can admit new entries some 
times, but we still leave the high-sketch-frequency low-recency collision at 
the bottom of the queue; that item will still be the one we compare candidates 
against most of the time. Choosing the threshold using the random walk, but 
ejecting the item at the bottom of the queue means the collision can go away.

TinyLFU chooses whether to admit a new item. LRU (which doesn't suffer from 
collision effects) chooses which item to evict if we do.

> Cache implementation using LIRS eviction for in-process page cache
> ------------------------------------------------------------------
>
>                 Key: CASSANDRA-11452
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-11452
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Local Write-Read Paths
>            Reporter: Branimir Lambov
>            Assignee: Branimir Lambov
>
> Following up from CASSANDRA-5863, to make best use of caching and to avoid 
> having to explicitly marking compaction accesses as non-cacheable, we need a 
> cache implementation that uses an eviction algorithm that can better handle 
> non-recurring accesses.



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

Reply via email to