From 1d4039b5ab210852170a3be7ea3a03f50507e449 Mon Sep 17 00:00:00 2001 From: Binbin Date: Mon, 17 Jun 2024 17:09:44 +0800 Subject: [PATCH 1/2] Both LRU, LFU and volatile-ttl are implemented using approximated randomized algorithms Signed-off-by: Binbin --- topics/lru-cache.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/topics/lru-cache.md b/topics/lru-cache.md index fccec2ba..03afff48 100644 --- a/topics/lru-cache.md +++ b/topics/lru-cache.md @@ -57,6 +57,8 @@ The following policies are available: The policies **volatile-lru**, **volatile-lfu**, **volatile-random**, and **volatile-ttl** behave like **noeviction** if there are no keys to evict matching the prerequisites. +Both **LRU**, **LFU** and **volatile-ttl** are implemented using approximated randomized algorithms. + Picking the right eviction policy is important depending on the access pattern of your application, however you can reconfigure the policy at runtime while the application is running, and monitor the number of cache misses and hits From 326ebde5174748f72ba9bcdf3686c1cf83a9ffad Mon Sep 17 00:00:00 2001 From: Binbin Date: Mon, 17 Jun 2024 18:27:57 +0800 Subject: [PATCH 2/2] Update topics/lru-cache.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Binbin Co-authored-by: Viktor Söderqvist --- topics/lru-cache.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/topics/lru-cache.md b/topics/lru-cache.md index 03afff48..5468ca46 100644 --- a/topics/lru-cache.md +++ b/topics/lru-cache.md @@ -57,7 +57,7 @@ The following policies are available: The policies **volatile-lru**, **volatile-lfu**, **volatile-random**, and **volatile-ttl** behave like **noeviction** if there are no keys to evict matching the prerequisites. -Both **LRU**, **LFU** and **volatile-ttl** are implemented using approximated randomized algorithms. +**LRU**, **LFU** and **volatile-ttl** are implemented using approximated randomized algorithms. Picking the right eviction policy is important depending on the access pattern of your application, however you can reconfigure the policy at runtime while