Practice
Solution
Step 1: Trace Delivery Worker decision at Step 4 -- read model update
The Delivery Worker must ensure the read model is updated before committing the Kafka offset to avoid data loss.Step 2: Understand failure handling
On transient DB errors, the worker retries to guarantee eventual consistency; discarding or committing offset prematurely risks data loss.Final Answer:
Option D -> Option DQuick Check:
Retry read model update before offset commit -> ensures consistency [check]
Solution
Step 1: Identify stateful bottleneck
Chat servers maintain WebSocket connections statefully, limiting horizontal scaling.Step 2: Understand scaling impact
At 10x scale, existing WebSocket connections cannot be moved, causing chat servers to saturate first.Final Answer:
Option C -> Option CQuick Check:
Stateful WebSocket servers bottleneck scaling before DB or load balancer [check]
Solution
Step 1: Analyze scaling characteristics of CDN components
Origin servers can be scaled horizontally; DNS is stateless and highly distributed; load balancers can be scaled or replaced.Step 2: Identify edge node bottleneck
Edge nodes have fixed cache storage and network bandwidth per PoP; scaling traffic 10x stresses these resources first.Final Answer:
Option B -> Option BQuick Check:
Edge nodes limited by cache and bandwidth -> bottleneck at 10x scale [check]
Solution
Step 1: Identify stateful components limiting scale
WebSocket servers maintain persistent connections per user, which are stateful and bound to server memory.Step 2: Analyze scaling challenges
At 10x scale, adding servers doesn't migrate existing WebSocket connections, causing uneven load and resource exhaustion. Relational DB (A) can be sharded, cache (B) can be scaled with TTL tuning, storage (D) scales with cloud object storage.Final Answer:
Option C -> Option CQuick Check:
Stateful WebSocket connections limit horizontal scaling [check]
Solution
Step 1: Analyze stateful components at scale
Chat servers maintain stateful WebSocket connections bound to server memory; scaling requires connection migration which is complex.Step 2: Compare other components
Database (A) and brokers (B) can be scaled horizontally with sharding and replication; producers (D) can be scaled out by adding more instances.Final Answer:
Option C -> Option CQuick Check:
Stateful WebSocket servers bottleneck scaling due to connection affinity [check]
