Code Room
System designMediumsd-g001
Subject Messaging queuesLevel Mid–Senior~35 minCommon in Distributed systems interviewsIndustries Technology, Software development

Question

Design the order-dispatch queue for a food-delivery platform that routes ~50k new orders/min at peak to a fleet of courier-assignment workers. Each restaurant's orders must be processed in the sequence they were placed, assignment must complete within 2 seconds p95, and a worker crash must not silently drop an order. Walk through the queueing topology, how you preserve per-restaurant ordering without serializing the whole system, and how you handle a poison order that repeatedly fails assignment.

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.

Narrate your design
Loading whiteboard…
Run or narrate your approach, then ask the coach.