From 058788fe057e0f5fe93387c6ac62ea64f515b2ff Mon Sep 17 00:00:00 2001 From: Ankur Anand Date: Sat, 4 Oct 2025 11:22:12 +0530 Subject: [PATCH 1/2] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 1c01d53..0a8253e 100644 --- a/README.md +++ b/README.md @@ -11,13 +11,13 @@ A high-performance, generic **Hierarchical Timing Wheel** implementation in Go f When you need to manage thousands or millions or timers (timeouts, TTLs, scheduled tasks) etc. While Go's standard `time.Timer` is excellent, it faces some challenges at high volumes. -## Use Case: Expiring 10 Million Cache Keys Efficiently +### Example: How a Timing Wheel Handles 10 Million Cache Keys Traditional cache cleanup scans every key (`O(n)`), which works fine at small scale — but completely breaks down once you hit **millions** of entries. Using a **Timing Wheel**, expiration becomes `O(1)` per tick — processing *only* the keys that are actually due right now. -### Read Stall Comparison (10 Million Keys) +#### Read Stall Comparison (10 Million Keys) |**Metric**|**Naive Scan**|**Timing Wheel**| |:-|:-|:-| From cbdebee52571a48cb6383965761b02a7e9667ef2 Mon Sep 17 00:00:00 2001 From: Ankur Anand Date: Sat, 4 Oct 2025 11:23:32 +0530 Subject: [PATCH 2/2] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 0a8253e..18e0a03 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ A high-performance, generic **Hierarchical Timing Wheel** implementation in Go f When you need to manage thousands or millions or timers (timeouts, TTLs, scheduled tasks) etc. While Go's standard `time.Timer` is excellent, it faces some challenges at high volumes. -### Example: How a Timing Wheel Handles 10 Million Cache Keys +### How a Timing Wheel Efficiently Expires 10 Million TTL-Based Cache Keys Traditional cache cleanup scans every key (`O(n)`), which works fine at small scale — but completely breaks down once you hit **millions** of entries.