-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: Replication
-
None
-
Fully Compatible
-
ALL
-
Repl 2017-03-27
-
0
After stopping the FSM and CRUD clients, this test should call ReplSetTest.awaitReplication() before querying the current primary with awaitNodesAgreeOnPrimary() and getPrimary():
jstests/noPassthrough/libs/backup_restore.js:360
backup_restore.js
// Wait up to 5 minutes until the new hidden node is in state SECONDARY. rst.waitForState(hiddenNode, ReplSetTest.State.SECONDARY); // Wait for secondaries to finish catching up before shutting down. rst.awaitNodesAgreeOnPrimary(); primary = rst.getPrimary(); assert.writeOK(primary.getDB("test").foo.insert( {}, {writeConcern: {w: rst.nodes.length, wtimeout: 10 * 60 * 1000}})); // Stop set. rst.stopSet();