-
Type: Question
-
Resolution: Done
-
Priority: Minor - P4
-
None
-
Affects Version/s: 2.6.5
-
Component/s: Replication
-
None
In Manager::msgCheckNewState, if findOtherPrimary finds that two other members think they are primary, the method returns without having done anything. I think in the (unlikely) case where there are > 2 primaries, this may be problematic.
If there are > 2 primaries, each primary will notice that at least 2 other primaries exist (by having bool two set to true when calling findOtherPrimary), and bail. As a result, no primary steps down.
Instead, perhaps the function should continue, and noteARemoteIsPrimary should loop through all members checking if there is any primary with a more recent election time, and step down if that is the case. msgCheckNewState will then return anyway given that a primary exists.
I realize that with the 30 second election timer, having > 2 primaries is incredibly difficult, but if the timer is removed this issue may become more likely.