diff options
author | Bernard Gorman <bernard.gorman@gmail.com> | 2018-10-15 14:13:53 -0400 |
---|---|---|
committer | Bernard Gorman <bernard.gorman@gmail.com> | 2018-10-23 00:19:01 +0100 |
commit | 1e19472175d9f8c26d2cc1a80e108a0a4a761213 (patch) | |
tree | ff798bd9801eb65585ee8096a86f0461373f1833 /src/mongo/db/index/wildcard_key_generator.h | |
parent | 10ec78a0ea0adca815df5a5cb9f3bf9f7d2221f6 (diff) | |
download | mongo-1e19472175d9f8c26d2cc1a80e108a0a4a761213.tar.gz |
SERVER-37566 Avoid recreating ProjectionExecAgg on each expansion of a wildcard index
Diffstat (limited to 'src/mongo/db/index/wildcard_key_generator.h')
-rw-r--r-- | src/mongo/db/index/wildcard_key_generator.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mongo/db/index/wildcard_key_generator.h b/src/mongo/db/index/wildcard_key_generator.h index 106e30ba8a4..7c17b929eaf 100644 --- a/src/mongo/db/index/wildcard_key_generator.h +++ b/src/mongo/db/index/wildcard_key_generator.h @@ -58,6 +58,13 @@ public: const CollatorInterface* collator); /** + * Returns a pointer to the key generator's underlying ProjectionExecAgg. + */ + const ProjectionExecAgg* getProjectionExec() const { + return _projExec.get(); + } + + /** * Applies the appropriate Wildcard projection to the input doc, and then adds one key-value * pair to the BSONObjSet 'keys' for each leaf node in the post-projection document: * { '': 'path.to.field', '': <collation-aware-field-value> } |