[Top Question: System Design Tech Case Study Pulse #88]Massive Infra: How Facebook Messenger Handles 20 Billion Messages Daily And How it Actually Works
With detailed explanation and flow chart....
Hi All,
Facebook Messenger's choice of Apache HBase as its backend storage system enables it to handle an astounding 20 billion messages daily. This feat allows Facebook to provide real-time messaging services to billions of users worldwide with high reliability and low latency.
Learn how to System design —Design Lyft
Today in this post, let me dive deep into how Facebook engineered this system, exploring the key architectural decisions, scaling strategies, and optimizations that enable HBase to manage this massive volume of messages for Messenger.
System Overview
Before I delve into the HBase architecture for Facebook Messenger, let's look at some key metrics that highlight the scale of its operations:
- Messages processed daily: 20 billion+
- Active users: 1.3 billion+
- Peak messages per second: Millions
- Data stored: Petabytes
- Latency: Low milliseconds for message delivery
- Availability: 99.99%+
- Global deployment: Multiple data centers worldwide
- Supported message types: Text, images, videos, voice messages, etc.
- Devices supported: Mobile apps, web browsers, IoT devices
How Real World Scalable Systems are Build — 200+ System Design Case Studies:
System Design Den : Must Know System Design Case Studies
100K Events per Second : How Uber Real-Time Surge Pricing Actually Works
Processing 2 Billion Daily Queries : How Facebook Graph Search Actually Works
1.5 Billion Swipes per Day : How Tinder Matching Actually Works
500+ Million Users Daily : How Instagram Stories Actually Work
7 Trillion Messages Daily : Magic Behind LinkedIn Architecture and How It Actually Works
3 Billion Daily Active Users : How Facebook News Feed Algorithm Actually Works
1 Billion Tweets Daily : Magic Behind Twitter Scaling and How It Actually Works
12 Million Daily Users: Inside Slack's Real-Time Messaging Magic and How it Actually Works
3 Billion Daily Users : How Youtube Actually Scales
20 Billion Messages Daily: How Facebook Messenger Actually Works
8+ Billion Daily Views: How Facebook's Live Video Ranking Algorithm Works
How Discord's Real-Time Chat Scales to 200+ Million Users
80 Million Photos Daily : How Instagram Achieves Real Time Photo Sharing
Serving 1 Trillion Edges in Social Graph with 1ms Read Times : How Facebook TAO works
How Lyft Handles 2x Traffic Spikes during Peak Hours with Auto scaling Infrastructure..
How it works ( tech in depth) —
1. User Interaction:
- A user sends a message through a Messenger client (mobile app, web, etc.).
- The message is sent to Messenger Application Servers.
2. Message Processing:
- Application Servers process the message, applying Timeline Consistency checks.
- The HBase Client Library prepares the write operation.