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

RollbackTestFixture doesn't need to wait for a new primary if it didn't shut down the current primary

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.2.3, 4.3.3, 4.0.20
    • Affects Version/s: None
    • Component/s: Replication
    • None
    • Fully Compatible
    • ALL
    • v4.2, v4.0
    • Repl 2018-10-22, Repl 2018-11-05, Repl 2019-09-23, Repl 2019-11-18, Execution Team 2019-12-16, Repl 2019-12-02, Repl 2019-12-16, Execution Team 2020-01-13, Execution Team 2019-12-30
    • 33

      The rollback fuzzer suites utilize the RollbackTestFixture to run randomized rollback testing. Some of the suites (e.g. rollback_fuzzer_clean_shutdowns) will shut down nodes at random times. After we shutdown a node, we wait until there is a stable primary so that we can continue doing writes in the test. The way we check this can be racy, though, if we get a current primary that then steps down, and we get that same node as a secondary. Instead of asserting that the primary and secondary are not equal, I think it would be simpler to just check if we shut down the original primary. If so, then we need to wait for a new primary. Otherwise, we shouldn't need to wait, since the original primary should be stable, since it is supported by an arbiter.

            suganthi.mani@mongodb.com Suganthi Mani
            william.schultz@mongodb.com William Schultz
            0 Vote for this issue
            6 Start watching this issue