HLDArena
HLD-417·Search & Indexing
Expert · 2,000 pts

Separated Storage/Compute Cloud Data Warehouse Query Engine

Design a BigQuery / Databricks Photon-style multi-tenant analytical SQL control & metadata plane featuring immutable columnar micro-partitions in object storage, MVCC snapshot metadata pruning, ephemeral NVMe compute-cache rings, and instant ACID table commits.

Max p99
≤ 70 ms
Availability
≥ 99.6%
Budget
≤ $11,600

Functional Requirements

  • FR-1POST /v1/tables/{table_id}/commits — Atomically commits new immutable Parquet/columnar micro-partition manifests via optimistic MVCC.
  • FR-2POST /v1/queries/plan-prune — Prunes min/max zone-map metadata against snapshot_id and schedules locality-aware compute executors.
  • FR-3DELETE /v1/tables/{table_id}/snapshots/expired — Compacts small streaming micro-partitions and reclaims expired time-travel blobs safely.
  • FR-4Must guarantee snapshot isolation across concurrent streaming DML writers + 230k+ metadata/cache RPS when primary catalog shards crash.

Workload Profile

BI Dashboard & ETL Load80,000 Zone-Map & Result Cache Read RPS / 13,000 Streaming Commit Write RPS
Monday 9 AM Executive BI Storm205,000 Read RPS / 31,000 Micro-Partition Commit RPS
Active Working Set58 GB hot table snapshot trees, column min/max zone maps & result caches
ACID InvariantSerializable MVCC manifest commits + consistent hash NVMe micro-partition affinity

Consistency Model

Strict optimistic MVCC CAS on table head snapshot_id so concurrent streaming inserts and compactions never drop committed micro-partitions.

Relevant practice for

Click an item in Inventory above, or press B to add a component, double-click to name, C to connect.

Design Write-up

Write under ### Architecture for Diagram to take that up directly

Compulsory section · if not written yet, Diagram reads from the start of your write-up.
Architecture: required·FRs mentioned: 0/4·0 boxes · 0 edges
0 words
Hidden Cases #4–#7 run automatically on Submit
Case 1: Smoke & API ContractInput Workload
Read RPS
2,000 rps
Write RPS
400 rps
Key Distribution
Uniform (Low Skew)
Chaos Fault
None (Healthy Cluster)
Expected Pass CriteriaASSERTIONS
• Tail Latency: p99 ≤ 140 ms
• Availability: ≥ 99.6%
Valid end-to-end Client → Compute → Storage topology