summaryrefslogtreecommitdiff
path: root/src/mongo/shell/collection.js
diff options
context:
space:
mode:
authorNick Zolnierz <nicholas.zolnierz@mongodb.com>2018-03-20 17:30:14 -0400
committerNick Zolnierz <nicholas.zolnierz@mongodb.com>2018-04-04 14:42:00 -0400
commit527386807d3fc2897542e90539e3f5230922c865 (patch)
treeb12ccf54e0408d88e6f76319e50cdd5e5dd478ca /src/mongo/shell/collection.js
parentea14c46d8a5b8d33412ef2c62b09475fe8533976 (diff)
downloadmongo-527386807d3fc2897542e90539e3f5230922c865.tar.gz
SERVER-33818: Add 'resumeWithClusterTime' as an alias for '$_resumeAfterClusterTime' in $changeStream
Diffstat (limited to 'src/mongo/shell/collection.js')
-rw-r--r--src/mongo/shell/collection.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mongo/shell/collection.js b/src/mongo/shell/collection.js
index 871b3ad3710..89eda930e8b 100644
--- a/src/mongo/shell/collection.js
+++ b/src/mongo/shell/collection.js
@@ -1500,6 +1500,11 @@ DBCollection.prototype.watch = function(pipeline, options) {
delete options.resumeAfter;
}
+ if (options.hasOwnProperty("startAtClusterTime")) {
+ changeStreamStage.startAtClusterTime = options.startAtClusterTime;
+ delete options.startAtClusterTime;
+ }
+
pipeline.unshift({$changeStream: changeStreamStage});
// Pass options "batchSize", "collation" and "maxAwaitTimeMS" down to aggregate().
return this.aggregate(pipeline, options);