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

make replica_set_error_codes.js more robust

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.7.2
    • Affects Version/s: None
    • Component/s: Replication
    • None
    • Fully Compatible
    • Repl 2018-02-12, Repl 2018-02-26
    • 0

      Currently, replica_set_error_codes.js has asserts that a particular node must become secondary. But it is not guaranteed that this node will always win because the other secondary may also run for an election and win instead.

      Just call .getPrimary() instead, which blocks until a new primary is elected.

            Assignee:
            pavithra.vetriselvan@mongodb.com Pavithra Vetriselvan
            Reporter:
            pavithra.vetriselvan@mongodb.com Pavithra Vetriselvan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: