beginnerDistributed Systems — Replication, Partitioning & Consistency

What is consistent hashing and why is it important for distributed databases?

Consistent hashing maps both keys and nodes to positions on a virtual ring (0 to 2^32). A key belongs to the first node clockwise from its hash position. Advantage over naive modulo hashing (key % numNodes): When you add/remove nodes with modulo hashing: almost all keys remapped (massive data movement). With consistent hashing: only the keys in the affected range need to move (typically 1/N of dat

This is a Pro chapter

Sign in, then upgrade to Pro or Power to unlock this and the full Databases Mastery library.

What is consistent hashing and why is it important for distributed databases?

Next Step

Continue to A write to your distributed database succeeded but the user can't see their update. What could be happening and how do you fix it?← Back to all NoSQL questions