Try
↑ ↓ move↵ openesc close
In this lesson · topic 7 of 7
  1. 1. Why hash mod N hurts
  2. 2. The ring and virtual nodes
  3. 3. Add a node to the ring and to mod N
  4. 4. What the ring balances and what it leaves
  5. 5. How many virtual nodes is enough
  6. 6. Rendezvous hashing and Maglev tables
  7. 7. Check ownership, balance and hot keys

Topic 7

Check ownership, balance and hot keys

3 min read

Predict first

On a consistent hashing ring, a new node joins. Which keys move?

Predict first

What problem do virtual nodes solve?

Predict first

A single key receives a huge share of requests. Does consistent hashing fix the hot spot?

Take away

  • Hash mod N is even but moves most keys when N changes.
  • A ring moves only the keys next to the change.
  • Virtual nodes trade memory for balance.

Sources

Your progress is saved in this browser. Sign in to keep it on every device. Privacy · Terms