Skip to content

Instantly share code, notes, and snippets.

Feed Architecture: Firehose to Client

Complete end-to-end architecture for a live-updating social feed at scale.

Overview

Architecture Pattern: Redis cache + edge compute with O(1) atomic updates

  • Ingestion: Jetstream firehose → Redis (hash-per-post structure)
  • Query: Redis → Cloudflare Workers (edge) or AWS Lambda → Client (Brotli compressed)
  • Updates: Live metadata polling + incremental post fetches