summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenety Goh <benety@mongodb.com>2023-02-09 17:59:16 -0500
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2023-02-10 02:17:36 +0000
commit53478bd7dce5f14708fb35db41293df1ea79db33 (patch)
tree99718ec3f4e13f77da051bae9f81a1403e1f5073
parentbf7c308ffe91ae183fc9507b7297e183e5cff4cf (diff)
downloadmongo-53478bd7dce5f14708fb35db41293df1ea79db33.tar.gz
SERVER-73847 large batched writes rollback test provides nodeOptions to fixture
-rw-r--r--jstests/replsets/rollback_large_batched_multi_deletes.js42
1 files changed, 14 insertions, 28 deletions
diff --git a/jstests/replsets/rollback_large_batched_multi_deletes.js b/jstests/replsets/rollback_large_batched_multi_deletes.js
index 222aec120bf..8d2cc181d31 100644
--- a/jstests/replsets/rollback_large_batched_multi_deletes.js
+++ b/jstests/replsets/rollback_large_batched_multi_deletes.js
@@ -50,35 +50,20 @@ let RollbackOps = (node, rst) => {
};
// Set up Rollback Test.
-const rst = new ReplSetTest({
- name: jsTestName(),
- nodes: [
- {
- setParameter: {
- // On a slow machine, the default of 5 ms for 'batchedDeletesTargetBatchTimeMS'
- // may cause the batched delete stage to break up the delete operation into
- // smaller batches that not allow us to test the effect of
- // 'maxNumberOfBatchedOperationsInSingleOplogEntry' on
- // OpObserver::onBatchedWriteCommit().
- // Setting 'batchedDeletesTargetBatchTimeMS' to zero (for unlimited) ensures that
- // the delete stage will alway put all the requested deletes in a single batch.
- batchedDeletesTargetBatchTimeMS: 0,
- maxNumberOfBatchedOperationsInSingleOplogEntry: 2,
- },
- },
- {},
- {
- rsConfig: {priority: 0},
- },
- ],
- settings: {
- chainingAllowed: false,
+const nodeOptions = {
+ setParameter: {
+ // On a slow machine, the default of 5 ms for 'batchedDeletesTargetBatchTimeMS'
+ // may cause the batched delete stage to break up the delete operation into
+ // smaller batches that not allow us to test the effect of
+ // 'maxNumberOfBatchedOperationsInSingleOplogEntry' on
+ // OpObserver::onBatchedWriteCommit().
+ // Setting 'batchedDeletesTargetBatchTimeMS' to zero (for unlimited) ensures that
+ // the delete stage will alway put all the requested deletes in a single batch.
+ batchedDeletesTargetBatchTimeMS: 0,
+ maxNumberOfBatchedOperationsInSingleOplogEntry: 2,
},
- useBridge: true,
-});
-rst.startSet();
-rst.initiateWithHighElectionTimeout();
-const rollbackTest = new RollbackTest("RollbackTest", rst);
+};
+const rollbackTest = new RollbackTest(jsTestName(), /*replSet=*/undefined, nodeOptions);
if (!FeatureFlagUtil.isEnabled(rollbackTest.getPrimary(),
"InternalWritesAreReplicatedTransactionally")) {
@@ -90,6 +75,7 @@ if (!FeatureFlagUtil.isEnabled(rollbackTest.getPrimary(),
CommonOps(rollbackTest.getPrimary());
const rollbackNode = rollbackTest.transitionToRollbackOperations();
+const rst = rollbackTest.getTestFixture();
RollbackOps(rollbackNode, rst);
// Wait for rollback to finish.