Code Room
System designHardsd-g125
Subject Distributed transactionsLevel Senior–Staff~50 minCommon in Databases & SQL · Concurrency · Distributed systems interviewsIndustries Technology

Question

Design account-to-account transfers in a banking core where accounts are sharded across many database partitions (by account id), and a single transfer can move money between two accounts on different shards. ~9,000 transfers/sec. The transfer must be atomic (both legs apply or neither), durable, and exactly-once under client retries. Describe how you make a cross-shard debit+credit atomic without a single global lock and how you handle a coordinator crash mid-transfer.

What a strong answer looks like

Clarify scale and constraints first. Propose a clean component breakdown, then go deep on the hard parts — data model, bottlenecks, consistency, failure modes — and name the trade-offs you are making.

Narrate your design
Loading whiteboard…
Run or narrate your approach, then ask the coach.