Practice
Solution
Step 1: Trace Delivery Worker decision at Step 4 -- Bob's presence TTL
If Bob's presence key expired, it means Bob is offline. The worker should queue the message for offline delivery and mark it undelivered.Step 2: Eliminate wrong states
Delivering immediately (The Delivery Worker delivers the message immediately to Bob's device) ignores offline status. Deleting message (The Delivery Worker deletes the message assuming Bob is offline permanently) causes data loss. Retrying indefinitely (The Delivery Worker retries checking Bob's presence key indefinitely) blocks delivery pipeline.Final Answer:
Option B -> Option BQuick Check:
Expired presence -> queue for offline delivery [check]
Solution
Step 1: Trace Delivery Worker decision at Step 4 -- Bob's presence TTL
If TTL expired, recipient is offline; message can't be delivered immediately.Step 2: Understand offline delivery handling
Delivery Worker queues message for later delivery and marks status as 'sent but not delivered' to reflect state.Final Answer:
Option A -> Option AQuick Check:
Expired TTL -> queue message, status 'sent but not delivered' [check]
Solution
Step 1: Understand role of commit metadata DB
Commit metadata DB stores branch pointers; without it, server cannot persist new branches.Step 2: Trace branch creation failure
Client may create branch locally, but server cannot persist it, so branch is effectively lost or inconsistent.Step 3: Eliminate other options
Queuing without notification hides failure; immediate error is possible but not typical if client allows local ops; marking unverified branches requires metadata DB access.Final Answer:
Option D -> Option DQuick Check:
Metadata DB down -> branch created locally but not persisted [check]
Solution
Step 1: Evaluate cultural impact of blame vs blameless approaches
Blame-focused reports create fear and reduce openness, harming continuous improvement.Step 2: Assess effectiveness of blameless timelines with action items
They foster trust, encourage learning, and drive actionable improvements aligned with high-trust culture.Final Answer:
Option A -> Option AQuick Check:
Blameless + action items -> continuous improvement [check]
Solution
Step 1: Analyze timestamp and network constraints
Timestamp synchronization (A) is challenging but tolerable with NTP; network coordination (D) is minimal as IDs are generated locally.Step 2: Evaluate sequence number limits
Sequence number (B) limits per millisecond can cause blocking but can be mitigated by load balancing or sharding.Step 3: Identify machine ID allocation bottleneck
Machine ID bits are fixed (e.g., 10 bits), limiting the number of unique machines. At 10x scale, running out of unique machine IDs causes collisions or requires complex reallocation.Final Answer:
Option D -> Option DQuick Check:
Fixed machine ID bits limit scale -> collisions or reconfiguration needed [check]
