Reqflow
← All comparisons

Ad Click Aggregation vs Instagram Feed

Ad Click Aggregation

Ad Click Aggregation

High-volume event ingestion, exactly-once stream aggregation, time-windowed counts, lambda vs kappa architecture.

Components (8)

  • Ad Servers
  • Ingest API
  • Click Stream (Kafka)
  • Stream Processor (Flink)
  • Batch Processor (Spark)
  • Real-Time Store
  • Data Warehouse
  • Fraud Detector

Headline numbers

  • Ingest bandwidth~50 MB/sec
  • Raw event storage (30 days)~130 TB
  • Flink state size~10 GB
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 Ad Click Aggregation
None.
In both
  • Client
  • Api Gateway
  • Queue
  • Service
  • Database
Only in Instagram Feed
  • CDN
  • Redis
  • S3

Flow shape

Ad Click Aggregation flows
  • A click is ingested and counted4 steps
  • Hourly batch reconciliation2 steps
  • Flink worker crashes mid-window3 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