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

Prevent ReplSetTest.waitForState usage with SECONDARY state

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 8.1.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Replication
    • Fully Compatible
    • Repl 2024-12-09

      We have both ReplSetTest.waitForState and ReplSetTest.awaitSecondaryNodes that can be used wait for a node to become secondary. However, there's a subtle difference in reporting from the primary vs the actual node, so this behavior ends up becoming nuanced in practice. In this case, maybe we should error if a user tries to use waitForState as a means of waiting for the secondary state. The comment at the function signature says something to this effect, but we should start enforcing this behavior.

            Assignee:
            m.maher@mongodb.com Moustafa Maher
            Reporter:
            pavithra.vetriselvan@mongodb.com Pavithra Vetriselvan
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: