Caching Strategies: Write-Through, Write-Back, and TTL
Understand the major caching strategies for backend systems. Compare write-through, write-back, write-around, and cache-aside with real-world trade-offs.
14 posts · page 1 of 1
Understand the major caching strategies for backend systems. Compare write-through, write-back, write-around, and cache-aside with real-world trade-offs.
Compare Redis and Memcached for caching. Understand data structures, persistence, clustering, and use cases to choose the right caching solution.
Implement distributed locks with Redis. Covers single-instance locks, the Redlock algorithm, fencing tokens, lock renewal, and common pitfalls to avoid.
Implement rate limiting with token bucket, sliding window, and fixed window algorithms. Covers Redis-backed solutions, response headers, and distributed setups.
Speed up Django with Redis caching — per-view cache, template fragment cache, low-level cache API, and cache invalidation strategies.
Compare per-view, template fragment, low-level, and per-site caching in Django and learn when each pays off.
A practical guide to wiring Celery into Django for background work, scheduled jobs, and reliable task processing.
When FastAPI BackgroundTasks are enough, when you need Celery, and how to wire jobs that survive crashes, retries, and scale.
How to build GraphQL subscriptions that survive multiple server instances by using Redis as the pub/sub backbone. Covers setup, scaling, and the failure modes nobody warns you about.
Build a reliable background job system in Node.js using Redis and BullMQ, with queues, workers, retries, and scheduled jobs.
A practical look at distributed locking with Redis: SET NX EX, Redlock, fencing tokens, and the failure modes that cause data corruption.
Design a distributed cache using consistent hashing, replication, and eviction policies to speed up reads at internet scale.
Design a real-time leaderboard using Redis sorted sets, handling millions of score updates per second with low latency rankings.
Practical Redis caching patterns: cache-aside, write-through, TTL choices, stampede protection, and invalidation strategies that survive production.