Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-48928

Allow primary-elect to complete drain mode even if it is stepping down unconditionally

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 4.7.0, 4.2.10, 4.4.2, 4.0.21
    • Replication
    • None
    • Fully Compatible
    • ALL
    • v4.4, v4.2, v4.0
    • Repl 2020-07-27, Repl 2020-08-10

    Description

      We call ReplicaSetAwareServiceRegistry::onStepUpComplete and ReplicationCoordinatorExternalState::onTransitionToPrimary before calling _topCoord->completeTransitionToPrimary, which can fail.

      If it does fail, we don't seem to take any action to inform the external services we just told we were now primary that we actually no longer are.

       

      To resolve this, we will allow nodes to complete drain mode, even if their action is set to kSteppingDown. This will let us invariant on the second check, instead of returning a Status.

      Attachments

        Issue Links

          Activity

            People

              xuerui.fa@mongodb.com Xuerui Fa
              spencer@mongodb.com Spencer Brody (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: