HLD-107·Coordination & IDs
Easy · 500 ptsDistributed 64-Bit ID & Sequence Service
Design a high-throughput unique ID allocation service issuing time-ordered 64-bit identifiers and range leases to internal microservices.
Max p99
≤ 22 ms
Availability
≥ 99.5%
Budget
≤ $1,850
Functional Requirements
- FR-1POST /v1/ids/batch — Allocates guaranteed-unique ID blocks or Snowflake worker leases.
- FR-2GET /v1/ids/{shard_id}/meta — Inspects shard epoch and worker lease health.
- FR-3DELETE /v1/ids/batch/{shard_id} — Releases canceled or expired leases/holds atomically and immediately refreshes cached availability.
- FR-4Must survive a primary state node crash without issuing duplicate IDs or stalling callers.
Workload Profile
Baseline Requests16,000 Read RPS / 6,500 Lease/Mint Write RPS
Peak Minting Surge42,000 Read RPS / 18,000 Write RPS
Active Working Set4 GB worker epoch & sequence lease state
Latency BudgetCore RPC dependency requiring p99 <= 22 ms
Consistency Model
Monotonic rough time-ordering per worker with durable lease checkpoints across replica nodes.
Solutions Locked
Sign in and either achieve AC or complete 3 official submissions on this question to inspect community diagrams and writeups.
Loading solutions...
Submission History (0)Select to replay
No submissions yet
Click Submit in the top bar to evaluate against all 7 judge cases and save each run here.
Design Write-up
0 boxes · 0 edges
0 words