Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Reddit/Quora Software System Design
1. Methodology for Reddit/Quora
1. 5 Step Process
1.1. Use cases, assumptions, constraints
1.2. Back of envelope calculations
1.3. Design core components
1.4. High level design
1.5. Scale the design
2. Reddit/Quora
Step 1a: Use Cases
● Functional requirements (use cases)
○ Users posts a topic
○ User reacts to a topic (comment, like)
○ Notification service when a reaction is on a topic
○ User search a topic
● Nonfunctional requirements
○ High availability
4. Reddit/Quora
Step 2a: Back of envelope calculations
● Database design
○ Users
■ Id
■ Name
■ Topics_associated
○ Topics
■ Id
■ Topic_name
■ Created_at
■ Participants_progress (object with users_id and timestamps)
○ Reactions
■ Id
■ Reaction_type
■ Content
■ Topic_id
■ User_id
■ Created_at
5. Reddit/Quora
Step 2b: Back of envelope calculations
● Daily traffic
○ 10 million users/daily
○ 100,000 reactions/sec
○ 33% of users reacts daily
■ 3:1 read-write
● Storage
○ Tables of Users (~50 bytes), Topics (~100 bytes), Reactions
(~350 bytes)
■ ~500 bytes * 100,000 reactions/sec
● 50 MB/s
6. Reddit/Quora
Step 3: Design core components
● Use case #1: User create a topic
○ Server, Write API, database
● Use case #2: Users react to a topic
○ Server, Write API, Read API, database, object store
● Use case #3: Notification service
○ Server, Write API, database, notification service
● Use case #4: Users search for a topic
○ Server, database, Search API, search service