beginnerRedis — Data Structures, Persistence & Pub/Sub

What are the Redis persistence options and when do you use each?

RDB (Redis Database Backup): periodic snapshots of the entire dataset to a binary file. Config: save 900 1 (save if 1 change in 900s), save 60 10000 (if 10000 changes in 60s). Pros: fast recovery from snapshots; compact file. Cons: data loss between snapshots. AOF (Append Only File): logs every write command. Config: appendonly yes; appendfsync everysec (flush to disk every second). Pros: near-zer

Ready to master this question?

Generate a complete walkthrough — background, the full answer in plain language, a working code example explained line by line, a real-world scenario, common mistakes, and how this same question gets asked in different ways.

Sign in to generate a response

Next Step

Continue to What is a Redis Sorted Set and what are its use cases?← Back to all NoSQL questions