cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Benedict (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (CASSANDRA-11452) Cache implementation using LIRS eviction for in-process page cache
Date Sat, 16 Apr 2016 21:32:25 GMT

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

Benedict edited comment on CASSANDRA-11452 at 4/16/16 9:31 PM:
---------------------------------------------------------------

bq. Sadly Ehcache3 did this for their randomly sampled LRU

Ah, but they were _evicting_ a random sample: here we only want to randomly admit, and since
we're protecting from a biased sample of too high a threshold, and we're looking for (thereabouts)
the _lowest_ frequency in the map, we shouldn't ever negatively impact performance, only possibly
be slightly slow to respond to these attacks.  With an Iterator we'd eventually visit the
entire map too, so we'd be absolutely guaranteed to be robust (without higher costs of "sampling"
- I should clarify that for the Iterator and ideal direct CHM bucket "sampling" I simply meant
picking a single random guard key).

That doesn't take away from what I said though: we're almost certainly achieving as much robustness
as we need, and the algorithm you sketched there looks fine to me.


was (Author: benedict):
bq. Sadly Ehcache3 did this for their randomly sampled LRU

Ah, but they were _evicting_ a random sample: here we only want to randomly admit, and since
we're protecting from a biased sample of too high a threshold, and we're looking for (thereabouts)
the _lowest_ frequency in the map, we shouldn't ever negatively impact performance, only possibly
be slightly slow to respond to these attacks.  With an Iterator we'd eventually visit the
entire map too, so we'd be absolutely guaranteed to be robust.

That doesn't take away from what I said though: we're almost certainly achieving as much robustness
as we need, and the algorithm you sketched there looks fine to me.

> 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)

Mime
View raw message