forked from scylladb/scylladb
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
loading_cache: implement a variation of least frequent recently used …
…(LFRU) eviction policy This patch implements a simple variation of LFRU eviction policy: * We define 2 dynamic cache partitions which total size should not exceed the maximum cache size. * New cache entry is always added to the "new generation" partition. * After a cache entry is read more than PartitionHitThreshold times it moves to the second cache partition. * Both partitions' entries obey expiration and reload rules as before this patch. * When cache entries need to be evicted due to a size restriction "new generation" partition least recently used entries are evicted first. Fixes scylladb#8674 Signed-off-by: Vlad Zolotarov <vladz@scylladb.com>
- Loading branch information
1 parent
34cf92f
commit 3cd19ca
Showing
6 changed files
with
161 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters