Preparing your design workspace

Loading the problem and your latest saved attempt…

Design a Fleet Insurance Registration Platform

Design a tenant-isolated platform that validates large fleet-policy registrations, atomically activates a complete fleet version, and reliably notifies the organization after success.

Problem statement

Design an end-to-end platform where a fleet organization that has already purchased vehicle-insurance policies in bulk can register its insured fleet and receive a notification after registration succeeds.

For this exercise, assume an upstream identity service authenticates the organization and supplies a stable organization ID. Each registration is an immutable uploaded file that maps every vehicle VIN to one purchased policy number and its coverage dates.

A submission moves from RECEIVED to PROCESSING and then to exactly one terminal state, REGISTERED or REJECTED. The new fleet version becomes active only when every row passes validation; readers must observe either the previous complete version or the new complete version.

For this exercise, allow at most one PROCESSING submission per organization, make client and worker retries idempotent, and keep every record, transition, and notification organization-scoped and auditable.

After REGISTERED commits, record one logical success email and deliver it asynchronously; an email-provider failure must never roll back the registration. Policy purchase, pricing, underwriting, issuer verification, billing, claims, renewals, and taxi dispatch are outside scope.

What to build

  1. For this exercise, an authenticated organization can idempotently submit one immutable fleet-policy file for asynchronous validation and receive a stable submission ID.
  2. For this exercise, the organization can inspect submission progress, terminal outcome, and bounded row-level validation findings without seeing another organization's data.
  3. For this exercise, a valid submission atomically becomes the organization's readable active fleet version with its vehicle-policy associations, while a rejected submission activates no rows and leaves the previous version readable.
  4. For this exercise, the platform records one logical email only after registration commits, retries delivery with a stable identity, and exposes delivery state without rolling registration back.

At scale

  • Source fact: one fleet organization may already hold vehicle-insurance policies in bulk and needs end-to-end registration plus a notification after successful registration.
  • Practice assumption: support 100,000 registered organizations and 10 million active vehicle-policy associations, with immutable registration files containing up to 100,000 rows.
  • Practice assumption: handle peaks of 50 new submissions per second, durably acknowledge submission within 1 second at p95, and serve status reads within 300 milliseconds at p95.
  • Practice assumption: 99 percent of maximum-size files reach REGISTERED or REJECTED within 15 minutes, and a healthy email provider receives the success email within 1 minute of registration.
  • Practice assumption: upload, queue, and worker operations may execute at least once, and the system must resume after worker or availability-zone failure without losing accepted submissions or duplicating activation and notification effects.