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

ReplSetTest initiated with seed member throws error on shutdown

    • Type: Icon: Bug Bug
    • Resolution: Works as Designed
    • Priority: Icon: Minor - P4 Minor - P4
    • None
    • Affects Version/s: None
    • Component/s: Replication
    • Labels:
      None
    • Replication
    • ALL

      In theory, we can create a ReplSetTest fixture from a seed node that is part of an existing replica set, like 'new ReplSetTest("host:123")'. The test queries the RS config and initiates its own data structures as if it had initiated the set itself. However, ReplSetTest.stop() fails:

      checkDBHashesForReplSet going to check data hashes on secondary: jesse-workstation:20022
      uncaught exception: TypeError: replSetConfig.members[rst.getNodeId(...)] is undefined :
      checkDBHashesForReplSet/<@src/mongo/shell/replsettest.js:2510:47
      checkDBHashesForReplSet@src/mongo/shell/replsettest.js:2387:17
      ReplSetTest/this.checkReplicaSet@src/mongo/shell/replsettest.js:2303:13
      ReplSetTest/this.checkReplicatedDataHashes@src/mongo/shell/replsettest.js:2588:9
      RollbackTest/this._checkDataConsistencyImpl@jstests/replsets/libs/rollback_test.js:249:9
      RollbackTest/this.checkDataConsistency@jstests/replsets/libs/rollback_test.js:255:9
      

      The fixture doesn't initialize its "members" array when constructed with a seed node.

            Assignee:
            backlog-server-repl [DO NOT USE] Backlog - Replication Team
            Reporter:
            jesse@mongodb.com A. Jesse Jiryu Davis
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: