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

Race in write_concern_after_stepdown.js

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 4.2.9, 4.4.1, 4.7.0
    • Replication
    • None
    • Fully Compatible
    • ALL
    • v4.4, v4.2
    • 32

    Description

      We expect the parallel shell to begin a w: majority write on Node 0, while Node 0 is primary and replication is blocked. Then Node 0 steps down and the parallel shell expects to receive PrimarySteppedDown.

      In fact, the parallel shell took a long time to begin. It finally connected after Node 0 had already stepped down. When it began its w: majority write it received

      w:majority write replied: {
        "ok" : 0,
        "errmsg" : "not master",
        "code" : 10107,
        "codeName" : "NotMaster"
      }
      

      This is not a "write error" but a generic command failure, so when the shell calls assert.writeErrorWithCode it logs unhelpfully:

      assert: found code(s) [ ] does not match any of the expecte d codes [ 189, 11602 ]
      

      Attachments

        Issue Links

          Activity

            People

              jesse@mongodb.com A. Jesse Jiryu Davis
              jesse@mongodb.com A. Jesse Jiryu Davis
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: