Consumer Messaging Platform — WhatsApp-Class System  ·  View 04 of 23

Container Architecture

The deployable units, their technology, and the protocol on every link — C4 level 2 for the messaging core.

Editable source SVG draw.io All views
Client devices
Client devices
Primary device
Primary device
Chat Application
Swift / Kotlin
Chat Application...
Encrypted Local DB
SQLCipher
Encrypted Local DB...
Key Store
Secure Enclave / Keystore
Key Store...
Companion devices
Companion devices
Desktop & Web Client
Electron / WASM
Desktop & Web Client...
Companion Session Store
Companion Session Store
Edge tier
Edge tier
Point of presence
Point of presence
Anycast Terminator
TLS 1.3
Anycast Terminator...
Connection Gateway
Erlang/OTP, 1M sockets/pool
Connection Gateway...
Edge control
Edge control
Session Registry
Redis Cluster
Session Registry...
Auth & Rate Guard
Device-scoped tokens
Auth & Rate Guard...
Core services — Kubernetes
Core services — Kubernetes
Messaging
Messaging
Chat Service
Go, idempotent accept
Chat Service...
Fanout Service
Go, sharded workers
Fanout Service...
Receipt Service
Receipt Service
Identity & social
Identity & social
Account Service
Registration, profile
Account Service...
Group & Community Service
Group & Community Service
Key Distribution Service
Public prekeys only
Key Distribution Service...
Rich features
Rich features
Media Service
Resumable upload
Media Service...
Call Signalling Service
WebRTC SDP relay
Call Signalling Service...
Status Service
24 h TTL
Status Service...
Data tier
Data tier
Operational stores
Operational stores
Message Store
ScyllaDB, RF 3
Message Store...
Account & Group DB
Sharded MySQL
Account & Group DB...
Cache & async
Cache & async
Presence Cache
Redis
Presence Cache...
Delivery Queue
Per-device inbox
Delivery Queue...
Event Bus
Kafka
Event Bus...
Blob & keys
Blob & keys
Media Object Store
Immutable, TTL 30 d
Media Object Store...
Backup Key Vault
HSM-backed
Backup Key Vault...
APNs / FCM
APNs / FCM
Global CDN
Global CDN
STUN / TURN
STUN / TURN
SMS OTP Provider
SMS OTP Provider
Noise over TCP 443
Noise over TCP 443
Noise over WSS
Noise over WSS
gRPC
gRPC
ciphertext write
ciphertext write
per-device enqueue
per-device enqueue
deliver on socket
deliver on socket
encrypted blob
encrypted blob
origin pull
origin pull
verification code
verification code
relay allocation
relay allocation
Container Architecture
Container Architecture
Application we own
Application we own
Data store
Data store
Security / platform
Security / platform
Interface / broker
Interface / broker
Queue / topic
Queue / topic
External / third party
External / third party
synchronous
synchronous
event / async
event / async
Push dispatch, business API gateway and observability agents omitted for legibility.
Push dispatch, business API gateway and observability agents omitted for legibility.
v 1.0 · owner Platform Architecture · date 2026-08
v 1.0 · owner Platform Architecture · date 2026-08
Text is not SVG - cannot display

Runtime choices

  • Connection Gateway on Erlang/OTP: millions of cheap processes, one per socket
  • Stateless Go services for accept, fanout, receipts, groups and media
  • ScyllaDB for the message store — wide rows keyed by device, TTL-driven purge

Statefulness

  • Gateways are stateful in connections only; the session registry rebuilds on reconnect
  • Chat Service is idempotent on client_msg_id so retries are free
  • Delivery queues are durable per device, not per account

Omitted for legibility

  • Push dispatcher, business API gateway and telemetry sidecars
  • Twelve edges shown out of roughly forty in the real dependency graph