| ▲ | __turbobrew__ 6 months ago | |||||||
| Why not just make the nodes even from the start? Place new nodes in the largest existing gap between any pair of nodes. | ||||||||
| ▲ | lsecondario 6 months ago | parent | next [-] | |||||||
| In a distributed system all clients would need to agree on the largest existing gap under various messaging anomalies. If you have a mechanism to reach that agreement then you can probably use a simpler deterministic load balancing algo. Consistent hashing gives you eventually consistent routing without (synchronous) agreement. | ||||||||
| 
 | ||||||||
| ▲ | sfilipov 6 months ago | parent | prev | next [-] | |||||||
| Worth mentioning that virtual nodes also ensure that the order of servers is random. Which helps when a server is removed - the keys that need to be moved will be spread across all other servers. If we were to evenly chop up the hash ring, server B will always be after server A. And when we remove server A, all keys residing on it will need to be moved exclusively to server B. | ||||||||
| 
 | ||||||||
| ▲ | remram 6 months ago | parent | prev [-] | |||||||
| Whatever balanced configuration you make, it will become imbalanced if you add or remove a node. | ||||||||