summaryrefslogtreecommitdiff
path: root/jstests/replsets/chaining_removal.js
diff options
context:
space:
mode:
authorMoustafa Maher <m.maher@10gen.com>2021-04-29 01:19:06 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2021-04-29 23:07:54 +0000
commit0d97b041970929e7e56caa42ee8837cec92d2264 (patch)
tree3508368450bd271faed556cfb298624da9cb9543 /jstests/replsets/chaining_removal.js
parent15fb9ff89f2074704735c0a8629d0013b530747b (diff)
downloadmongo-0d97b041970929e7e56caa42ee8837cec92d2264.tar.gz
SERVER-55703 Update getDefaultRWConcern
Diffstat (limited to 'jstests/replsets/chaining_removal.js')
-rw-r--r--jstests/replsets/chaining_removal.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/jstests/replsets/chaining_removal.js b/jstests/replsets/chaining_removal.js
index 5244f653071..71d0a5b9aab 100644
--- a/jstests/replsets/chaining_removal.js
+++ b/jstests/replsets/chaining_removal.js
@@ -23,6 +23,11 @@ replTest.initiate({
});
replTest.awaitNodesAgreeOnPrimary(replTest.kDefaultTimeoutMS, nodes, nodes[0]);
var primary = replTest.getPrimary();
+// The default WC is majority and stopServerReplication could prevent satisfying any majority
+// writes.
+assert.commandWorked(primary.adminCommand(
+ {setDefaultRWConcern: 1, defaultWriteConcern: {w: 1}, writeConcern: {w: "majority"}}));
+
replTest.awaitReplication();
// When setting up chaining on slow machines, we do not want slow writes or delayed heartbeats