Cache strategies¶
How to use cache¶
- Use cache with data that is read frequently but modified infrequently
- Use persistent data stores in case cache server would be restarted
- Expiration policy
- Consistency. Sync cache and data store. Read more "Scaling Memcache at Facebook"
- Mitigating failures.
- Eviction Policy.
- Least-recently-used (LRU)
- Least Frequently Used (LFU)
- First in First Out (FIFO)