summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMisha Tyulenev <misha.tyulenev@mongodb.com>2020-07-08 23:05:03 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-07-10 16:39:11 +0000
commit0497a5fe38903ceb08c48050df476f0718b91733 (patch)
treeaffedd34a0922d3c508ca21d557f8a0631cf1990
parentd6f3aebf450e53dd41ca31947cc0cc9ccf30e1bc (diff)
downloadmongo-0497a5fe38903ceb08c48050df476f0718b91733.tar.gz
SERVER-49090 fail with MovePrimaryInProgress for aggregate and stages
-rw-r--r--jstests/sharding/move_primary_with_writes.js23
1 files changed, 23 insertions, 0 deletions
diff --git a/jstests/sharding/move_primary_with_writes.js b/jstests/sharding/move_primary_with_writes.js
index 11d9e8f6150..9cc940ee902 100644
--- a/jstests/sharding/move_primary_with_writes.js
+++ b/jstests/sharding/move_primary_with_writes.js
@@ -57,6 +57,29 @@ function buildCommands(collName) {
alwaysFail: false
},
{command: {delete: collName, deletes: [{q: {_id: 0}, limit: 1}]}, alwaysFail: false},
+ {
+ command: {
+ aggregate: collName,
+ cursor: {},
+ pipeline: [
+ {$match: {_id: 0}},
+ {
+ $merge: {
+ into: "testMergeColl",
+ on: "_id",
+ whenMatched: "replace",
+ whenNotMatched: "insert"
+ }
+ }
+ ]
+ },
+ alwaysFail: true
+ },
+ {
+ command:
+ {aggregate: collName, cursor: {}, pipeline: [{$match: {}}, {$out: "testOutColl"}]},
+ alwaysFail: true
+ },
{command: {create: "testCollection"}, alwaysFail: true},
{
command: {collMod: "viewOnFoo", viewOn: "unshardedFoo", pipeline: [{$match: {_id: 1}}]},