Leadership will choose lowest node by `systemName` order and not by address
akbashev opened this issue · comments
Jaleel Akbashev commented
Current implementation of Comparable protocol from ClusterEndpoint is using description string, and thus creates a problem—it contains systemName
in it and most important it comes before host and port. So when selectByLowestAddress
kicks in Leadership
it will sort nodes and choose lowest not by address, but by alphabetical order (or guess unicode order) of systemName
node's variables.
As systemName
is actually internal and not so important quick solution could be just to remove it from node comparison.