• antirez's avatar
    Fix configEpoch assignment when a cluster slot gets "closed". · e4833ed8
    antirez authored
    This is still code to rework in order to use agreement to obtain a new
    configEpoch when a slot is migrated, however this commit handles the
    special case that happens when the nodes are just started and everybody
    has a configEpoch of 0. In this special condition to have the maximum
    configEpoch is not enough as the special epoch 0 is not unique (all the
    others are).
    
    This does not fixes the intrinsic race condition of a failover happening
    while we are resharding, that will be addressed later.
    e4833ed8
cluster.c 151 KB