PracHub
QuestionsPremiumLearningGuidesInterview PrepNEWCoaches
|Home/System Design/TikTok

Explain Redis design, persistence, and scaling

Last updated: Mar 29, 2026

Quick Overview

This question evaluates understanding of Redis internals and operational trade-offs across core data structures, persistence options, memory eviction, high availability and sharding, transactions and scripting, distributed locking, and large-scale cache reliability.

  • hard
  • TikTok
  • System Design
  • Software Engineer

Explain Redis design, persistence, and scaling

Company: TikTok

Role: Software Engineer

Category: System Design

Difficulty: hard

Interview Round: Technical Screen

Explain Redis core data structures (strings, lists, sets, sorted sets, hashes, streams) and typical time/space characteristics. Compare RDB and AOF persistence, including durability, performance, and recovery trade-offs. Describe eviction policies and TTL behavior under memory pressure. Explain replication, Sentinel failover, and Cluster sharding. Discuss transactions, Lua scripting, and pitfalls of distributed locks (e.g., clock skew, fencing tokens). Outline strategies to prevent cache stampede and handle hotspot keys.

Quick Answer: This question evaluates understanding of Redis internals and operational trade-offs across core data structures, persistence options, memory eviction, high availability and sharding, transactions and scripting, distributed locking, and large-scale cache reliability.

Related Interview Questions

  • Choose tools for scalable distributed systems - TikTok (medium)
  • Design a distributed key-value store - TikTok (medium)
  • Design a content moderation system - TikTok (medium)
  • Design low-latency large-scale hotel booking system - TikTok (medium)
  • Explain SRE architecture and troubleshooting scenarios - TikTok (hard)
TikTok logo
TikTok
Jul 15, 2025, 12:00 AM
Software Engineer
Technical Screen
System Design
2
0

Redis: Data Structures, Persistence, Eviction, High Availability, and Operational Pitfalls

Context: You are designing a latency-critical backend that relies on Redis both as a cache and as a data store. Explain the following topics to demonstrate practical, production-oriented understanding.

  1. Core data structures
    • Strings, Lists, Sets, Sorted Sets (ZSET), Hashes, Streams
    • Typical time and space characteristics
  2. Persistence mechanisms
    • Compare RDB and AOF: durability, performance, recovery trade-offs
  3. Memory pressure
    • Eviction policies and TTL behavior under memory pressure
  4. High availability and scaling
    • Replication, Sentinel failover, and Cluster sharding
  5. Programmatic semantics
    • Transactions, Lua scripting
  6. Distributed locks
    • Pitfalls (e.g., clock skew, process pauses, network partitions) and fencing tokens
  7. Cache reliability at scale
    • Strategies to prevent cache stampede and handle hotspot keys

Solution

Show

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More System Design•More TikTok•More Software Engineer•TikTok Software Engineer•TikTok System Design•Software Engineer System Design
PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.