← All comparisons

Notification System vs Instagram Feed

Notification System

Notification System

Multi-channel async delivery, user preferences, retries.

Components (9)

  • Producer App
  • API Gateway
  • Notification Service
  • Postgres
  • Kafka
  • Email Worker
  • SMS Worker
  • Push Worker
  • Email / SMS / Push

Headline numbers

  • Notifications / sec (avg)~12K
  • Total delivery attempts / sec~19K
  • Idempotency key TTL~7 days
Instagram Feed

Instagram Feed

Fan-out on write vs read, ranking, CDN.

Components (10)

  • Mobile Client
  • CDN
  • API Gateway
  • Feed Service
  • Post Service
  • Kafka
  • Fan-out Worker
  • Redis
  • Postgres
  • S3

Headline numbers

  • Posts / sec (avg)~3,000/sec
  • Feed read QPS~58,000/sec
  • Fan-out writes / sec~600,000/sec

Key differences

Only in Notification System
  • Email / SMS / Push
In both
  • Client
  • Api Gateway
  • Service
  • Database
  • Queue
Only in Instagram Feed
  • CDN
  • Redis
  • S3

Flow shape

Notification System flows
  • Send a notification (multi-channel)8 steps
  • SendGrid is down5 steps
Instagram Feed flows
  • Post a photo (fan-out on write)7 steps
  • Open feed (precomputed timeline)5 steps
  • Fan-out Worker is down7 steps
  • Timeline cache flushed (Redis restart)4 steps