diff options
author | David Storch <david.storch@mongodb.com> | 2021-03-05 12:18:02 -0500 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2021-03-05 21:40:22 +0000 |
commit | a6b5cdc3fa1722ea241a3d1ff9575a82e4a46081 (patch) | |
tree | afb988ed96f0c4b917b866aafe780ce7f91d44e3 /src | |
parent | 8fc03988ff0cdf087b9108aff3a649e59f45cddb (diff) | |
download | mongo-a6b5cdc3fa1722ea241a3d1ff9575a82e4a46081.tar.gz |
SERVER-54832 make SBE stage builder tassert() that index exists in catalog
Diffstat (limited to 'src')
-rw-r--r-- | src/mongo/db/query/sbe_stage_builder_index_scan.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mongo/db/query/sbe_stage_builder_index_scan.cpp b/src/mongo/db/query/sbe_stage_builder_index_scan.cpp index 0ee2521b83b..863a2824ed8 100644 --- a/src/mongo/db/query/sbe_stage_builder_index_scan.cpp +++ b/src/mongo/db/query/sbe_stage_builder_index_scan.cpp @@ -687,6 +687,10 @@ std::pair<std::unique_ptr<sbe::PlanStage>, PlanStageSlots> generateIndexScan( auto descriptor = collection->getIndexCatalog()->findIndexByName(opCtx, ixn->index.identifier.catalogName); + tassert(5483200, + str::stream() << "failed to find index in catalog named: " + << ixn->index.identifier.catalogName, + descriptor); auto accessMethod = collection->getIndexCatalog()->getEntry(descriptor)->accessMethod(); auto intervals = makeIntervalsFromIndexBounds(ixn->bounds, |