diff options
author | James Wahlin <james@mongodb.com> | 2019-03-07 08:30:27 -0500 |
---|---|---|
committer | James Wahlin <james@mongodb.com> | 2019-04-11 14:59:55 -0400 |
commit | 6b47868e5a82822a21176db3a7d3abd2df429e1f (patch) | |
tree | ca2adddd4590b62cdefbc641d97cc58b5cc05479 /src/mongo/db/repl/storage_interface_impl.cpp | |
parent | 95bb948f7e5e573ca1473ba43dd6fd8e53cb5f50 (diff) | |
download | mongo-6b47868e5a82822a21176db3a7d3abd2df429e1f.tar.gz |
SERVER-40381 Add the ability to specify a pipeline to an update command
Diffstat (limited to 'src/mongo/db/repl/storage_interface_impl.cpp')
-rw-r--r-- | src/mongo/db/repl/storage_interface_impl.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mongo/db/repl/storage_interface_impl.cpp b/src/mongo/db/repl/storage_interface_impl.cpp index abb321c33c3..34128f17e80 100644 --- a/src/mongo/db/repl/storage_interface_impl.cpp +++ b/src/mongo/db/repl/storage_interface_impl.cpp @@ -907,7 +907,7 @@ Status StorageInterfaceImpl::upsertById(OperationContext* opCtx, // the event it was specified as a UUID. UpdateRequest request(collection->ns()); request.setQuery(query); - request.setUpdates(update); + request.setUpdateModification(update); request.setUpsert(true); invariant(!request.isMulti()); // This follows from using an exact _id query. invariant(!request.shouldReturnAnyDocs()); @@ -947,7 +947,7 @@ Status StorageInterfaceImpl::putSingleton(OperationContext* opCtx, const TimestampedBSONObj& update) { UpdateRequest request(nss); request.setQuery({}); - request.setUpdates(update.obj); + request.setUpdateModification(update.obj); request.setUpsert(true); return _updateWithQuery(opCtx, request, update.timestamp); } @@ -958,7 +958,7 @@ Status StorageInterfaceImpl::updateSingleton(OperationContext* opCtx, const TimestampedBSONObj& update) { UpdateRequest request(nss); request.setQuery(query); - request.setUpdates(update.obj); + request.setUpdateModification(update.obj); invariant(!request.isUpsert()); return _updateWithQuery(opCtx, request, update.timestamp); } |