Start learning

Redis: Voxel Defense

Operate a Redis deployment from its first key to a sharded production cluster, across 54 service contracts.

First chapter free, no account. Runs in your browser. Pricing

lessons
54
chapters
9
exams
9
hours, by design
8–12
lines of code
0
Redis: Voxel Defense Lesson 30 · Skew and Failover · wave running

01 / Why play it

Would you approve this?

An AI will propose each of these with total confidence. Each is a lesson you can play.

  1. Redis 05 On a cache miss, each request loads the product from the database.

    Right.House of cards. A thousand readers missing the same key become a thousand identical queries at once. Play Redis

  2. Redis 11 Balances get their own instance with noeviction. The cache gets allkeys-lru.

    Right.This one holds. Eviction policy is set per instance, so the cache can never push out a balance. Play Redis

  3. Redis 19 Replication is on, so a failover loses nothing.

    Right.House of cards. Replication is asynchronous, so the promoted replica can be missing writes the primary already acknowledged. Play Redis

02 / Syllabus

54 lessons, 9 chapters.

Each lesson is a service contract. You read what the service owes, build for it, run the traffic and read the debrief. Every chapter ends in an exam that mixes what came before.

Chapter 01

First service

Keys, TTLs and cache-aside. What invalidation has to do, and what a stampede does to the database behind the cache.

  1. 01 First Ping Keys, string values, and request service
  2. 02 Counter Rush Atomic commands and lost updates
  3. 03 Borrowed Time Session lifetime, expiration, and TTL
  4. 04 Cache Gate Cache-aside, misses, and invalidation
  5. 05 Cold Start Cache stampedes and coordinated refresh
  6. 06 Opening Night correct and responsive caching Exam

Chapter 02

Data and memory

Which structure fits which job (hashes, sets, lists, sorted sets) and what eviction throws away when memory runs out.

  1. 07 Field Service Hashes and independent field updates
  2. 08 Members Only Sets and exact membership
  3. 09 The Conveyor Lists, queue direction, and bounded history
  4. 10 Live Rankings Sorted sets, scores, and ranges
  5. 11 Memory Tide Memory limits and eviction policy
  6. 12 Working-Set Storm data structures under memory pressure Exam

Chapter 03

Latency and atomicity

Where latency comes from: round trips, hot keys, unbounded commands. What MULTI/EXEC, WATCH and functions do and do not guarantee.

  1. 13 The Long Road Round trips, pipelining, and connection reuse
  2. 14 One Hot Key Concentrated command load and useful capacity
  3. 15 Read Carefully Bounded operations, keyspace scans, and large values
  4. 16 Atomic Bundles WATCH, MULTI/EXEC, and transaction error behavior
  5. 17 Functions at the Gate Bounded server-side logic and blocking execution
  6. 18 Rush-Hour Clinic diagnose latency and preserve atomicity Exam

Chapter 04

Durability and availability

What replication, RDB, AOF and WAIT each promise, and how Sentinel decides it is allowed to fail over.

  1. 19 Mirrors Asynchronous replication, offsets, and backlog
  2. 20 Snapshot Shelter RDB snapshots, backups, and restore cost
  3. 21 Write Journal AOF policies and rewrite overhead
  4. 22 Acknowledgement Budget WAIT and persistence acknowledgements
  5. 23 Sentinel Watch Sentinel discovery, quorum, and failover authorization
  6. 24 Recovery Day availability, persistence, and backups Exam

Chapter 05

Redis Cluster

How 16,384 hash slots route keys, why multi-key commands need hash tags, and what MOVED and ASK are telling the client.

  1. 25 Hash-Slot Layout Native Cluster, hash slots, and explicit cutover
  2. 26 Crossroads Cluster-aware clients and redirect meaning
  3. 27 Family Ties Hash tags and same-slot atomic work
  4. 28 Moving Day Atomic slot migration and live change transfer
  5. 29 Split Horizon Cluster majority, coverage, and failure domains
  6. 30 Skew and Failover skew, migration, routing, and failover Exam

Chapter 06

Messaging and work

Pub/Sub against Streams, consumer groups and pending entries, and why reclaimed work needs idempotent handlers.

  1. 31 Live Wire Pub/Sub delivery and sharded channels
  2. 32 Lasting Feed Stream entries, IDs, and retained history
  3. 33 Worker Harbor Consumer groups, pending entries, and acknowledgements
  4. 34 Lost Parcel Reclaim, duplicate delivery, and business idempotency
  5. 35 Queue Under Pressure Backpressure, trimming, and poison-message handling
  6. 36 Dispatch Strike live notifications and recoverable processing Exam

Chapter 07

Documents and retrieval

JSON documents, search schemas, and the trade between recall and cost in vector search.

  1. 37 Living Documents JSON paths and structured updates
  2. 38 Catalog Search Explicit search schemas and field types
  3. 39 Search Pressure Query selectivity, sorting, and index cost
  4. 40 Nearest Neighbors Vector distances, filtering, and exact reference results
  5. 41 Cost of Recall FLAT, HNSW, and approximate retrieval tradeoffs
  6. 42 Discovery Day structured, lexical, and vector retrieval Exam

Chapter 08

Specialized structures

GEO, bitmaps, HyperLogLog, Bloom filters and time series: when an approximate answer is the right one.

  1. 43 Near and Far GEO coordinates and bounded nearby queries
  2. 44 Mark the Day Bitmaps and dense identifier layouts
  3. 45 Count the Crowd HyperLogLog and approximate distinct unions
  4. 46 Membership Sieve Bloom filters and safe false-positive handling
  5. 47 Telemetry History Time Series retention and aggregation
  6. 48 Analytics Integration exact, approximate, spatial, and temporal answers Exam

Chapter 09

Production operations

ACLs and TLS, connection pooling and uncertain retries, upgrades, and how much headroom a failure needs.

  1. 49 Trust Boundary Authentication, ACL authorization, and TLS
  2. 50 Connections Everywhere Pooling, uncertain retries, and tracked client caches
  3. 51 Read the Signals Operational measurements and causal diagnosis
  4. 52 Upgrade Lane Planned maintenance and readiness before cutover
  5. 53 Failure Budget Cost, capacity headroom, and recovery demand
  6. 54 The Long Night operate the complete Redis service Exam

03 / The model

What the simulation does, and what it skips.

This is a deterministic teaching model based on the Redis Open Source 8.10 documentation. It is not a Redis server and it does not provision one.

Modelled

  • Commands run against resident datasets with real expiry, types, transactions and WATCH.
  • Replication streams and backlogs, RDB and AOF images, promotion, and Sentinel authorization.
  • All 16,384 CRC16 hash slots, hash tags, and slot migration that consumes real capacity while it runs.
  • Fixed-step scheduling with CPU and network queues, primary and replica reads, and origin traffic on cache misses.
  • Streams, JSON, search, GEO, bitmaps, HyperLogLog, Bloom filters and time series, each backed by concrete fixtures.
  • Correctness is sampled throughout a run. Fixing a setting late does not erase an earlier violation.

Simplified or left out

  • Vector search illustrates the recall and work trade; it does not reproduce production HNSW internals.
  • RDB and AOF capture abstracts the operating-system fork and fsync mechanics.
  • ACL, TLS, client caching and Pub/Sub disconnects are simulated fixtures. No real servers, credentials or networks are involved.

CPU units, bandwidth, memory overheads, prices and failure-detection delays are game units. Offsets are model megabytes, not RESP bytes.

Primary sources

Lesson 1 takes a few minutes.

Keys, string values, and request service.

Also in the library: Kafka: Cluster Defense