CACHING SOLUTION
REDIS:
Interactive tutorial : http://try.redis.io/
JAVA Implementation: https://www.tutorialspoint.com/redis/redis_java.htm
Advantages: https://www.tutorialspoint.com/redis/redis_quick_guide.htm
Redis Cluster
Redis Cluster
Alternative to Redis : Memcached
Caching Best Practices
- Validity
- High Hitrate
- Cache Miss
- TTL
There can be three ways to write in the cache
- Cache Aside
- Read Through cache
- Write through - Write to the Cache, then write to the DB and then return success
- Write around - Write to the DB and return success. When there is a cache miss the cache would be updates.
- Write back - Write to the Cache and return success. there is another system which asynchronously
Fault Tolerance for Cache
- Regular Interval Snapshot
- Log Reconstruction
Learn more about caching using this video
How to design a Distributed Cache ?
Reading
https://codeahoy.com/2017/08/11/caching-strategies-and-how-to-choose-the-right-one/
https://www.instaclustr.com/blog/redis-vs-memcached
No comments:
Post a Comment