Back to Blog
ConceptsJanuary 8, 202610 min read

5 Distributed Systems Concepts You Must Know

CAP Theorem, Consistent Hashing, and other core concepts every senior engineer should master.

1. The CAP Theorem

In a distributed system, you can only have two of the three: Consistency, Availability, and Partition Tolerance. Since network partitions are unavoidable (P), you must choose between CP (strong consistency, like banking apps) or AP (high availability, like social media feeds).

2. Consistent Hashing

When distributing keys across N servers, simple modulo hashing (key % N) fails if N changes (servers add/remove). Consistent hashing maps both keys and servers to a ring, minimizing data movement when the cluster resizes. This is fundamental to systems like DynamoDB and Cassandra.

3. Leader Election

In a cluster, who is in charge? Algorithms like Raft and Paxos ensure that nodes agree on a leader. The leader handles writes to ensure consistency, while followers replicate data.

4. Bloom Filters

A probabilistic data structure that tells you if an element might be in a set or definitely isn't. It's extremely memory efficient. Used by databases to avoid expensive disk lookups for non-existent rows.

5. Eventual Consistency

Achieving strong consistency across the globe is slow. Eventual consistency guarantees that if no new updates are made, all accesses will eventually return the last updated value. This is the backbone of modern high-scale web apps.

Ready to practice?

Take what you've learned and apply it in a realistic mock interview environment powered by AI.

Start Mock Interview