Challenge
Dispatch ran over phone calls, customers had no live view of their order, and there was nothing stopping an order from being assigned twice or only partly assigned.
Approach
Pushed every rider state change to the customer app in real time and moved dispatch from phone calls into an in-system queue, with PostgreSQL relational constraints guarding order assignment.
Results
Customers track orders live, riders work from a single queue with full run history, and the database itself prevents partial or duplicate assignments.
