summaryrefslogtreecommitdiff
path: root/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h')
-rw-r--r--src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h b/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h
index a08aa23777f..f6026f6ef3a 100644
--- a/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h
+++ b/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h
@@ -53,11 +53,6 @@ public:
const NamespaceString& nss,
ChunkVersion targetCollectionVersion) const final;
- std::unique_ptr<WriteSizeEstimator> getWriteSizeEstimator(
- OperationContext* opCtx, const NamespaceString& ns) const final {
- return std::make_unique<TargetPrimaryWriteSizeEstimator>();
- }
-
std::vector<FieldPath> collectDocumentKeyFieldsActingAsRouter(
OperationContext*, const NamespaceString&) const final {
// We don't expect anyone to use this method on the shard itself (yet). This is currently
@@ -76,15 +71,23 @@ public:
const Document& documentKey,
boost::optional<BSONObj> readConcern) final;
+ /**
+ * Inserts the documents 'objs' into the namespace 'ns' using the ClusterWriter for locking,
+ * routing, stale config handling, etc.
+ */
Status insert(const boost::intrusive_ptr<ExpressionContext>& expCtx,
const NamespaceString& ns,
- std::unique_ptr<write_ops::InsertCommandRequest> insertCommand,
+ std::vector<BSONObj>&& objs,
const WriteConcernOptions& wc,
boost::optional<OID> targetEpoch) final;
+ /**
+ * Replaces the documents matching 'queries' with 'updates' using the ClusterWriter for locking,
+ * routing, stale config handling, etc.
+ */
StatusWith<UpdateResult> update(const boost::intrusive_ptr<ExpressionContext>& expCtx,
const NamespaceString& ns,
- std::unique_ptr<write_ops::UpdateCommandRequest> updateCommand,
+ BatchedObjects&& batch,
const WriteConcernOptions& wc,
UpsertType upsert,
bool multi,