Redis tillhandahåller högtillgänglighet genom replikering (replikakopior av data), Redis Sentinel (automatisk övervakande av växling) och Redis Cluster (sharding + replikering). Att förstå dessa är viktigt för att köra Redis tillförlitligt i produktion.
Replikering — primär och replikor
PRIMARY (master) → handles writes; asynchronously replicates data to replicas
REPLICAS (slaves) → copies of the primary's data; can serve READS (read scaling)
Write → Primary → async replication → Replicas (eventually consistent)
✓ Redundancy (replicas have copies) + read scaling (reads offloaded to replicas)
✗ Replication is ASYNC → a small lag; a failover could lose very recent writes
