summaryrefslogtreecommitdiff
path: root/src/mongo/db/pipeline/document_source_match.cpp
diff options
context:
space:
mode:
authorDavid Storch <david.storch@10gen.com>2016-10-03 11:17:13 -0400
committerDavid Storch <david.storch@10gen.com>2016-10-03 16:13:51 -0400
commit8758a5c7be68effbc4a1f857787bfb7b201c6389 (patch)
tree4880b453167dcada211c278dbc34ff095e31d81c /src/mongo/db/pipeline/document_source_match.cpp
parentb8a5742ef7623640eb6977f14e25649bad661208 (diff)
downloadmongo-8758a5c7be68effbc4a1f857787bfb7b201c6389.tar.gz
SERVER-25038 add LiteParsedPipeline
This provides a way to do pre-parse validity checks. Full parsing of the Pipeline must be done under the collection lock, when the collation is known.
Diffstat (limited to 'src/mongo/db/pipeline/document_source_match.cpp')
-rw-r--r--src/mongo/db/pipeline/document_source_match.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/mongo/db/pipeline/document_source_match.cpp b/src/mongo/db/pipeline/document_source_match.cpp
index f5c4432bc31..8476c82a67d 100644
--- a/src/mongo/db/pipeline/document_source_match.cpp
+++ b/src/mongo/db/pipeline/document_source_match.cpp
@@ -28,7 +28,7 @@
#include "mongo/platform/basic.h"
-#include <cctype>
+#include "mongo/db/pipeline/document_source.h"
#include "mongo/db/jsobj.h"
#include "mongo/db/matcher/expression_algo.h"
@@ -36,8 +36,8 @@
#include "mongo/db/matcher/expression_leaf.h"
#include "mongo/db/matcher/extensions_callback_noop.h"
#include "mongo/db/pipeline/document.h"
-#include "mongo/db/pipeline/document_source.h"
#include "mongo/db/pipeline/expression.h"
+#include "mongo/db/pipeline/lite_parsed_document_source.h"
#include "mongo/stdx/memory.h"
#include "mongo/util/stringutils.h"
@@ -49,7 +49,9 @@ using std::unique_ptr;
using std::string;
using std::vector;
-REGISTER_DOCUMENT_SOURCE(match, DocumentSourceMatch::createFromBson);
+REGISTER_DOCUMENT_SOURCE(match,
+ LiteParsedDocumentSourceDefault::parse,
+ DocumentSourceMatch::createFromBson);
const char* DocumentSourceMatch::getSourceName() const {
return "$match";