summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXueruiFa <xuerui.fa@mongodb.com>2021-08-09 21:08:38 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-01-04 19:53:04 +0000
commit2e3933d29e692c50d04b02a240b4b75a124d564e (patch)
tree16c0430f5f50a585ba33eb3cc805ae897973c61b
parent160cc06cd9dc4861ebe0678ed1a9286e21aef8ab (diff)
downloadmongo-2e3933d29e692c50d04b02a240b4b75a124d564e.tar.gz
SERVER-58135: Increase numInitialSyncAttempts for JS tests with chaining disabled
(cherry picked from commit 384542592c718d696b5c36d3cc67021c0844bb09)
-rw-r--r--jstests/replsets/initial_sync_chooses_correct_sync_source.js2
-rw-r--r--jstests/replsets/stepdown_needs_electable_secondary.js2
-rw-r--r--jstests/replsets/update_commit_point_from_sync_source_ignores_term.js7
3 files changed, 6 insertions, 5 deletions
diff --git a/jstests/replsets/initial_sync_chooses_correct_sync_source.js b/jstests/replsets/initial_sync_chooses_correct_sync_source.js
index 73236a0c031..fd2a5c2aded 100644
--- a/jstests/replsets/initial_sync_chooses_correct_sync_source.js
+++ b/jstests/replsets/initial_sync_chooses_correct_sync_source.js
@@ -42,7 +42,6 @@ const restartAndWaitForHeartbeats = (rst, initialSyncNode, setParameterOpts = {}
setParameterOpts['failpoint.initialSyncHangBeforeChoosingSyncSource'] =
tojson({mode: 'alwaysOn'});
setParameterOpts['failpoint.initialSyncHangBeforeCreatingOplog'] = tojson({mode: 'alwaysOn'});
- setParameterOpts['numInitialSyncAttempts'] = 1;
rst.restart(initialSyncNode, {
startClean: true,
@@ -84,7 +83,6 @@ const initialSyncNode = rst.add({
setParameter: {
'failpoint.initialSyncHangBeforeChoosingSyncSource': tojson({mode: 'alwaysOn'}),
'failpoint.initialSyncHangBeforeCreatingOplog': tojson({mode: 'alwaysOn'}),
- 'numInitialSyncAttempts': 1
}
});
primary.delayMessagesFrom(initialSyncNode, delayMillis);
diff --git a/jstests/replsets/stepdown_needs_electable_secondary.js b/jstests/replsets/stepdown_needs_electable_secondary.js
index 128c1297ef6..1fdb0bc8f43 100644
--- a/jstests/replsets/stepdown_needs_electable_secondary.js
+++ b/jstests/replsets/stepdown_needs_electable_secondary.js
@@ -32,7 +32,7 @@ var replTest = new ReplSetTest({
name: name,
nodes: 5,
nodeOptions: {
- setParameter: {logComponentVerbosity: tojson({replication: 2})},
+ setParameter: {logComponentVerbosity: tojson({replication: 2}), numInitialSyncAttempts: 25},
}
});
var nodes = replTest.nodeList();
diff --git a/jstests/replsets/update_commit_point_from_sync_source_ignores_term.js b/jstests/replsets/update_commit_point_from_sync_source_ignores_term.js
index 37065be798a..b0f0c6c3b1c 100644
--- a/jstests/replsets/update_commit_point_from_sync_source_ignores_term.js
+++ b/jstests/replsets/update_commit_point_from_sync_source_ignores_term.js
@@ -12,8 +12,11 @@ const dbName = "test";
const collName = "coll";
// Set up a ReplSetTest where nodes only sync one oplog entry at a time.
-const rst = new ReplSetTest(
- {nodes: 5, useBridge: true, nodeOptions: {setParameter: "bgSyncOplogFetcherBatchSize=1"}});
+const rst = new ReplSetTest({
+ nodes: 5,
+ useBridge: true,
+ nodeOptions: {setParameter: {bgSyncOplogFetcherBatchSize: 1, numInitialSyncAttempts: 25}}
+});
rst.startSet();
const config = rst.getReplSetConfig();
// Ban chaining and prevent elections.