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, 7 insertions, 10 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 f6026f6ef3a..a08aa23777f 100644
--- a/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h
+++ b/src/mongo/db/pipeline/process_interface/shardsvr_process_interface.h
@@ -53,6 +53,11 @@ 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
@@ -71,23 +76,15 @@ 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::vector<BSONObj>&& objs,
+ std::unique_ptr<write_ops::InsertCommandRequest> insertCommand,
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,
- BatchedObjects&& batch,
+ std::unique_ptr<write_ops::UpdateCommandRequest> updateCommand,
const WriteConcernOptions& wc,
UpsertType upsert,
bool multi,