Skip to content

Reference

Dispatch Matching

Select and reserve the best available supply for a demand request under changing location, availability, ETA, fairness, and concurrency constraints.

3 min read

After this, you will understand

How Dispatch Matching helps you see where this idea appears in production systems, what problem forces it, and how to reason about the tradeoffs.

Article guideprerequisites, mental models, and concepts

Article overview

advancedModelingReliabilityOperations

Three useful mental models

In plain terms

Treat the idea as a definition to memorize.

Production pressure

Real systems force the idea to handle Candidate Selection, Supply And Demand, and ETA Ranking.

Better reasoning

Use the concept to decide what the system guarantees, what it risks, and what it costs to operate.

Think before reading

Where would Dispatch Matching appear in a real production system, and what failure or bottleneck would it help you reason about?

As you read, look for the pressure that creates the idea first. The mechanics matter more once the reason is clear.

Concepts Covered

  • Supply and demand matching
  • Candidate driver selection
  • ETA-based ranking
  • Assignment reservation
  • Driver rejection and timeout
  • Fairness and marketplace effects
  • Race conditions

Definition

Dispatch matching is the process of choosing which available supply should serve a demand request.

In a ride-hailing system, demand is a rider requesting pickup. Supply is the set of drivers who are online, available, close enough, eligible for the trip type, and fresh enough to be trusted.

The matching system answers:

which driver should we offer this trip to right now?

That answer is not only about distance. It may consider ETA, driver state, rider constraints, fairness, cancellation risk, vehicle type, regional rules, and marketplace health.

The Pain That Forces Dispatch Matching

A naive system chooses the nearest driver.

That sounds reasonable until reality arrives:

  • the nearest driver location is stale
  • the nearest driver just accepted another trip
  • the nearest driver is across a one-way street or bridge
  • multiple riders request the same driver at once
  • the driver ignores the request
  • repeatedly choosing nearest drivers creates unfair supply distribution

Dispatch matching exists because the best assignment is a time-sensitive decision under uncertainty, not a simple distance sort.

Mental Model

Think of matching as a short-lived marketplace decision.

The system has:

demand: one rider request
supply: many possible drivers
constraints: eligibility, location freshness, availability, product rules
objective: low pickup ETA, reliable acceptance, fair marketplace behavior

The matcher first narrows candidates, then ranks them, then reserves one or more candidates through a controlled assignment workflow.

How It Works

A simplified flow:

1. Rider requests trip.
2. Matcher finds nearby available drivers through geospatial index.
3. Matcher filters stale, ineligible, or unavailable drivers.
4. Matcher estimates pickup ETA for candidates.
5. Matcher ranks candidates.
6. Assignment service leases a selected driver.
7. Driver receives offer.
8. Driver accepts, rejects, or times out.
9. If needed, matcher tries the next candidate.

The reservation step is crucial. Without it, multiple matching workers can offer the same driver to multiple riders.

Tradeoffs

Nearest driver is simple and explainable, but may be less reliable.

Batch matching can improve marketplace efficiency, but it adds latency and complexity.

Offering to one driver at a time avoids spam and double-booking, but can increase rider wait time if drivers reject or time out.

Offering to multiple drivers can reduce wait time, but it can create confusing driver experiences and race conditions.

Operational Reality

Important signals:

  • match latency
  • candidate count per request
  • driver acceptance rate
  • offer timeout rate
  • reassignment rate
  • stale candidate rate
  • rider cancellation rate
  • double-assignment prevention failures
  • pickup ETA error

Finished reading?

Your reading history is saved in this browser so you can continue later.

Recommended Next

URL Shortener SystemSystem Design16 min read

Return to the recommended System Design journey here. Start with a familiar service and watch production pressure force each architecture decision.

Optional exploration

These links add context, but they do not replace the recommended next lesson.

Arcflow Plus is coming — review drills, research breakdowns, more AI. Get one email at launch.