← All comparisons
Open Chat (Slack-style) →
Open URL Shortener →
Chat (Slack-style)
vs
URL Shortener
Chat (Slack-style rooms)
Chat (Slack-style rooms)
Room-based pub/sub fanout across gateway instances.
Components (6)
Sender
Recipient
WS Gateway
Chat Service
Postgres
Redis Pub/Sub
Headline numbers
WebSocket connections
~10M concurrent
Messages / sec
~3K avg, ~15K peak
Fan-out writes / sec
~30K
URL Shortener
URL Shortener
Hashing, key generation, read-heavy caching.
Components (6)
Client
API Gateway
Write Service
Read Service
Redis
Postgres
Headline numbers
Write QPS (avg)
~1,200/sec
Read QPS (avg)
~120,000/sec
Storage per year
~5 TB
Key differences
Only in Chat (Slack-style)
Redis Pub/Sub
In both
Client
Api Gateway
Service
Database
Only in URL Shortener
Redis
Flow shape
Chat (Slack-style) flows
Send to a room
6 steps
Reconnect and catch up
4 steps
⚠ Redis Pub/Sub is down
5 steps
URL Shortener flows
Shorten a URL
3 steps
Resolve short URL (cache hit)
3 steps
Resolve short URL (cache miss)
4 steps
⚠ Redis is down
4 steps