diff options
author | Andrii Dobroshynski <andrii.dobroshynski@mongodb.com> | 2021-06-25 03:58:21 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-06-30 14:52:00 +0000 |
commit | 1375ed058fd9737100fe00f845a54fe95cde79d2 (patch) | |
tree | 588c3c3ebbca7af645a0ff4abfc12b9512cddc09 /src/mongo/db/commands/mr_common.cpp | |
parent | 36341a87e2480634d4a84b58532d13b22e1e5dfb (diff) | |
download | mongo-1375ed058fd9737100fe00f845a54fe95cde79d2.tar.gz |
SERVER-57899 Expose accumulator name to make it more convenient to switch on type of AccumulatorStatement
Diffstat (limited to 'src/mongo/db/commands/mr_common.cpp')
-rw-r--r-- | src/mongo/db/commands/mr_common.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/db/commands/mr_common.cpp b/src/mongo/db/commands/mr_common.cpp index 46a0a0e6284..3bef28fae6b 100644 --- a/src/mongo/db/commands/mr_common.cpp +++ b/src/mongo/db/commands/mr_common.cpp @@ -130,7 +130,8 @@ auto translateReduce(boost::intrusive_ptr<ExpressionContext> expCtx, std::string AccumulationStatement jsReduce("value", AccumulationExpression(std::move(initializer), std::move(argument), - std::move(reduceFactory))); + std::move(reduceFactory), + AccumulatorInternalJsReduce::kName)); auto groupKeyExpression = ExpressionFieldPath::parse(expCtx.get(), "$emits.k", expCtx->variablesParseState); return DocumentSourceGroup::create(expCtx, |