LRU or LFU
Difficulty 2 of 5
A cache holds 1 million product pages, read 2,000 times per second. From 0:10 to 0:55 a nightly export reads 100 million other keys at 40,000 reads/s. Keep the hot-read hit ratio above 90 percent within 100 USD/mo.
Options
- LRU at 1.2 GB
- LRU at 20 GB
- LFU at 1.2 GB
Goals and limits
- Hit ratio (Hot)
- at least 90%
- p99 latency (Hot)
- under 150 ms
- Monthly cost
- under 100 USD/mo
- Traffic
- 2,000 req/s
Concepts
How players did
Player results load from the server.