Search DistillSys

Find a concept

Type at least two characters to search lessons, designs, papers, and interview prep.

Foundationsfundamental5 min read

Distributed Systems Fundamentals

Understand why teams distribute computation, what they gain, and which failure modes appear immediately.

2–5 minute refresher
Mental model

Independent machines + unreliable network + shared product promise

30second
refresher
A distributed system is a set of independent computers that cooperate to look like one product. Teams distribute work to scale capacity, place computation near users, isolate failures, and survive machine loss—but every network boundary introduces delay and uncertainty.

What problem does distribution solve?

One machine has finite CPU, memory, storage, and network capacity. It is also one fault domain. Distribution lets the system add capacity horizontally, replicate critical state, and continue when some components fail.

The core realities

  1. No shared clock: machines disagree about time.
  2. No instant global state: every observation may already be stale.
  3. Partial failure: one component can fail while the rest keep running.
  4. Finite coordination: stronger guarantees require communication, which costs latency and availability.
Decision guide

Key trade-offs

ChoiceWhat you gainWhat it costs
Horizontal scaleMore capacity and smaller fault domainsPartitioning, routing, and rebalancing
ReplicationAvailability and durabilityLag, conflicts, and coordination
Service boundariesIndependent ownership and deploymentRemote-call failure and operational complexity
What happens if?

A request times out after updating state

The client does not know whether the write failed or only the response failed. Retrying without an idempotency key can duplicate the operation; refusing to retry can lose the user’s intent.

Where this appears

Cloud services, databases, queues, caches, search engines, and even a mobile application talking to an API are distributed systems. The relevant question is not whether a product is distributed, but where its failure and consistency boundaries are.

Fundamental interview modeWhat makes a distributed system harder than a multithreaded program?Show answer
Independent failure, message delay or loss, and the absence of shared memory or a perfectly shared clock mean no participant can know the complete current state.
#fundamentals#reliability#scalability#failures