All projects

Case study — Backend · Geospatial

Repo

Geospatial Fleet Dispatch API

Proximity dispatch over MongoDB 2dsphere + WebSockets

FastAPI
MongoDB
Cloudflare Workers
Next.js
WebSockets

01The problem

Continuously tracking drivers and answering 'who is near this point' in real-time is a geometry problem as much as a networking one.

02Approach

  • 01Indexed locations with MongoDB 2dsphere for proximity lookups.
  • 02Solved 'nearest vehicles' with $geoNear queries.
  • 03Pushed live driver updates through a Next.js command-center UI over WebSockets.

03Outcomes

  • Real-time proximity mapping instead of brute-force scanning.
  • Live updates over WebSockets keep the command center current.
  • Serverless ingestion (Cloudflare Workers) side-steps tighten on the write path.