summaryrefslogtreecommitdiff
path: root/src/mongo/db/pipeline/process_interface/common_process_interface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/pipeline/process_interface/common_process_interface.cpp')
-rw-r--r--src/mongo/db/pipeline/process_interface/common_process_interface.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mongo/db/pipeline/process_interface/common_process_interface.cpp b/src/mongo/db/pipeline/process_interface/common_process_interface.cpp
index ae19e6a7635..b8a76b0b915 100644
--- a/src/mongo/db/pipeline/process_interface/common_process_interface.cpp
+++ b/src/mongo/db/pipeline/process_interface/common_process_interface.cpp
@@ -200,4 +200,11 @@ std::string CommonProcessInterface::getHostAndPort(OperationContext* opCtx) cons
return getHostNameCachedAndPort();
}
+void CommonProcessInterface::attachWriteConcern(BatchedCommandRequest* request,
+ const WriteConcernOptions& writeConcern) {
+ if (!writeConcern.usedDefault) {
+ request->setWriteConcern(writeConcern.toBSON());
+ }
+}
+
} // namespace mongo