← Questions

Design a globally consistent metadata service

0
AmazonSystem designLast asked Jan 2026

A system design interview question asked in Amazon's system design round, last asked Jan 2026. It tests consistency, replication and multi-region.

Design a metadata service used across several regions, for example the namespace of a storage system or the configuration of a global platform. It must be strongly consistent: once a write commits, every read anywhere returns it or something newer. Reads must still be fast, and the service must keep working, or degrade in a controlled way, when a region fails.

Requirements

  • Functional: create, read, update and delete metadata records; conditional writes (compare-and-set on a version); listing by prefix.
  • Non-functional: linearizable reads and writes; low read latency in every region; survives the loss of a region; clear behaviour during partitions; safe deploys and rollback.

Clarifying questions

  • What is the read-to-write ratio, and how large are the records and the whole dataset?
  • Does every read need to be linearizable, or can some callers accept slightly stale reads?
  • How many regions, and what is the round-trip time between them?
  • Which matters more during a partition: availability for writes or consistency?
  • Are there multi-record transactions?

What a strong answer covers

  • Partitioning the keyspace into shards, each replicated across regions by a consensus group (Raft or Paxos), and placing replicas so a quorum survives a region loss.
  • Why writes cost at least one cross-region quorum round trip, and how leader placement near the writers reduces it.
  • Fast linearizable reads: leader leases, read-index from followers, or synchronized clocks with bounded uncertainty, and the failure modes of each.
  • Versions on every record for compare-and-set and for caching with invalidation.
  • Region failure: leader election in a surviving region, what clients see during it, and degraded modes (serve stale reads with a flag, reject writes) chosen explicitly.
  • Operations: membership changes, rolling deploys, backups and restoring a shard, and how to roll back a bad release without losing writes.

Follow-ups

  • Some callers want reads in under 5 ms from a region far from the leader. What do you offer them, and what do they give up?
  • A shard becomes hot. How do you split it while staying consistent?
  • How do you test that the system is really linearizable?

Where it's asked

What it tests

consistency · replication · multi-region

Your canvas
Draw your answer hereBoxes, arrows and notes, saved for you to come back to.Sign in to start drawing