Code RoomDelayed job queue
MediumPrep Room Coding #3138

Delayed job queue

System designDistributed systemsMid–Senior~35 min

Design a delayed/scheduled job queue that lets services enqueue work to run at a specific future time — from seconds (retry-with-backoff) to months out (a subscription-renewal reminder) — at ~20k scheduled jobs/sec enqueue rate with tens of millions of pending jobs. Requirements: a job fires within a few seconds of its scheduled time, a due job is never lost or fired twice, and you can cancel or reschedule before it fires. Walk through the storage and dispatch.

What a strong answer looks like

Clarify scale and constraints first. Propose a clean component breakdown, then go deep on the hard parts (data model, bottlenecks, consistency, failure modes) and name the trade-offs you are making.

Clarify4:00 left
Estimate4:00 planned
Design11:30 planned
Deep dive9:30 planned
Failure6:00 planned
0:00
Which questions mattered is sealed until you submit. Telling you now would just be handing over the edge cases.