replmonitor_bad_seed.js should await primary node before writing to shard

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • 3.5.7
    • Affects Version/s: None
    • Component/s: Replication
    • None
    • Fully Compatible
    • ALL
    • Repl 2017-05-08
    • 0
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      replmonitor_bad_seed.js waits for the replica set nodes to be reachable but if a primary is not available (due to step downs for example), the write to the shard may fail:

          // Verify that the replSetMonitor can reach the restarted set
          awaitRSClientHosts(st.s0, replTest.nodes, {ok: true});
      
          assert.writeOK(st.s0.getDB('test').user.insert({x: 1}));
      

      We should call ReplSetTest.awaitNodesAgreeOnPrimary on the replica set before executing the sharded write.

            Assignee:
            Spencer Brody (Inactive)
            Reporter:
            Benety Goh
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: