• Ping Xie's avatar
    Introduce Shard IDs to logically group nodes in cluster mode (#10536) · 203b12e4
    Ping Xie authored
    Introduce Shard IDs to logically group nodes in cluster mode.
    1. Added a new "shard_id" field to "cluster nodes" output and nodes.conf after "hostname"
    2. Added a new PING extension to propagate "shard_id"
    3. Handled upgrade from pre-7.2 releases automatically
    4. Refactored PING extension assembling/parsing logic
    
    Behavior of Shard IDs:
    
    Replicas will always follow the shards of their reported primaries. If a primary updates its shard ID, the replica will follow. (This need not follow for cluster v2) This is not an expected use case.
    203b12e4
server.h 170 KB