diff options
author | Ian Boros <ian.boros@10gen.com> | 2018-10-09 12:22:08 -0400 |
---|---|---|
committer | Ian Boros <ian.boros@10gen.com> | 2018-11-06 11:24:25 -0500 |
commit | 36d4668e854d8bd17e8b684dbbf42b3b0903bbe7 (patch) | |
tree | 4815a0b5a9b712c5fb93f59e6a57d4cd6f0ae2f7 /src/mongo/db/commands/index_filter_commands.cpp | |
parent | a090ee789498e709eef4c2d28bc1326070c1e67a (diff) | |
download | mongo-36d4668e854d8bd17e8b684dbbf42b3b0903bbe7.tar.gz |
SERVER-33303 Add stable plan cache key and use for index filters
Diffstat (limited to 'src/mongo/db/commands/index_filter_commands.cpp')
-rw-r--r-- | src/mongo/db/commands/index_filter_commands.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mongo/db/commands/index_filter_commands.cpp b/src/mongo/db/commands/index_filter_commands.cpp index c9aec6823f9..f23760a4631 100644 --- a/src/mongo/db/commands/index_filter_commands.cpp +++ b/src/mongo/db/commands/index_filter_commands.cpp @@ -262,7 +262,7 @@ Status ClearFilters::clear(OperationContext* opCtx, } unique_ptr<CanonicalQuery> cq = std::move(statusWithCQ.getValue()); - querySettings->removeAllowedIndices(planCache->computeKey(*cq)); + querySettings->removeAllowedIndices(cq->encodeKey()); // Remove entry from plan cache planCache->remove(*cq).transitional_ignore(); @@ -395,7 +395,7 @@ Status SetFilter::set(OperationContext* opCtx, unique_ptr<CanonicalQuery> cq = std::move(statusWithCQ.getValue()); // Add allowed indices to query settings, overriding any previous entries. - querySettings->setAllowedIndices(*cq, planCache->computeKey(*cq), indexes, indexNames); + querySettings->setAllowedIndices(*cq, indexes, indexNames); // Remove entry from plan cache. planCache->remove(*cq).transitional_ignore(); |