summaryrefslogtreecommitdiff
path: root/src/mongo/db/pipeline/pipeline.h
diff options
context:
space:
mode:
authorCharlie Swanson <charlie.swanson@mongodb.com>2018-07-02 18:23:25 -0400
committerCharlie Swanson <charlie.swanson@mongodb.com>2018-08-15 13:30:12 -0400
commitee06e6cbe5a75775f76836449558be2f6a98ddfd (patch)
treed4dbf37110d25f7f4876337a7b1e11abe251fac5 /src/mongo/db/pipeline/pipeline.h
parenta5bde2f3e9afc3f72da01788b76829fb29c2f4e7 (diff)
downloadmongo-ee06e6cbe5a75775f76836449558be2f6a98ddfd.tar.gz
SERVER-33323 Refactor agg cursor merging on mongos
This commit makes it so that aggregations will always use a $mergeCursors as a wrapper around a AsyncResultsMerger, which is new behavior for mongos. As part of this refactor, we can delete the concept of a 'merging presorted' $sort stage (which is now handled by the AsyncResultsMerger) and delete the DocumentSourceRouterAdapter stage which talked to a RouterStageMerge, instead directly using a $mergeCursors stage.
Diffstat (limited to 'src/mongo/db/pipeline/pipeline.h')
-rw-r--r--src/mongo/db/pipeline/pipeline.h18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/mongo/db/pipeline/pipeline.h b/src/mongo/db/pipeline/pipeline.h
index 0bfb2602d2c..d4a2c813060 100644
--- a/src/mongo/db/pipeline/pipeline.h
+++ b/src/mongo/db/pipeline/pipeline.h
@@ -48,9 +48,9 @@
namespace mongo {
class BSONObj;
class BSONObjBuilder;
-class ExpressionContext;
-class DocumentSource;
class CollatorInterface;
+class DocumentSource;
+class ExpressionContext;
class OperationContext;
class PipelineDeleter;
@@ -172,17 +172,11 @@ public:
bool usedDisk();
/**
- * Split the current Pipeline into a Pipeline for each shard, and a Pipeline that combines the
- * results within mongos. This permanently alters this pipeline for the merging operation, and
- * returns a Pipeline object that should be executed on each targeted shard.
- */
- std::unique_ptr<Pipeline, PipelineDeleter> splitForSharded();
-
- /**
- * Returns true if this pipeline has not been split.
+ * Communicates to the pipeline which part of a split pipeline it is when the pipeline has been
+ * split in two.
*/
- bool isUnsplit() const {
- return _splitState == SplitState::kUnsplit;
+ void setSplitState(SplitState state) {
+ _splitState = state;
}
/**