diff options
author | Jack Mulrow <jack.mulrow@mongodb.com> | 2020-01-31 12:20:32 -0500 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-02-12 19:35:47 +0000 |
commit | 5c6b98259011bdffc57e33ad5dbbd622853ce2d4 (patch) | |
tree | 80af53b0ec3b1a436a0988d6cb638301283e00aa /jstests/sharding/libs | |
parent | 812c8338f496da3f43174330e37f07f0aad442d3 (diff) | |
download | mongo-5c6b98259011bdffc57e33ad5dbbd622853ce2d4.tar.gz |
SERVER-45908 Use explicit read concern in sharding test index consistency hook
Diffstat (limited to 'jstests/sharding/libs')
-rw-r--r-- | jstests/sharding/libs/sharded_index_util.js | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/jstests/sharding/libs/sharded_index_util.js b/jstests/sharding/libs/sharded_index_util.js index 778e4a4e94f..02289eb54f2 100644 --- a/jstests/sharding/libs/sharded_index_util.js +++ b/jstests/sharding/libs/sharded_index_util.js @@ -49,11 +49,13 @@ var ShardedIndexUtil = (function() { let getPerShardIndexes = function(coll) { return coll - .aggregate([ - {$indexStats: {}}, - {$group: {_id: "$shard", indexes: {$push: {spec: "$spec"}}}}, - {$project: {_id: 0, shard: "$_id", indexes: 1}} - ]) + .aggregate( + [ + {$indexStats: {}}, + {$group: {_id: "$shard", indexes: {$push: {spec: "$spec"}}}}, + {$project: {_id: 0, shard: "$_id", indexes: 1}} + ], + {readConcern: {level: "local"}}) .toArray(); }; |