← All comparisons

Notification System vs URL Shortener

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
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 Notification System
  • Kafka
  • Email / SMS / Push
In both
  • Client
  • Api Gateway
  • Service
  • Database
Only in URL Shortener
  • Redis

Flow shape

Notification System flows
  • Send a notification (multi-channel)8 steps
  • SendGrid is down5 steps
URL Shortener flows
  • Shorten a URL3 steps
  • Resolve short URL (cache hit)3 steps
  • Resolve short URL (cache miss)4 steps
  • Redis is down4 steps