diff options
author | Geir Storli <geirst@yahooinc.com> | 2024-04-08 13:33:47 +0000 |
---|---|---|
committer | Geir Storli <geirst@yahooinc.com> | 2024-04-08 13:33:47 +0000 |
commit | 8f054c2e362379858f3678f161a462472a962da3 (patch) | |
tree | ac6c0a25d82831b63f923b50d9d2ddf69658c82f /searchcore/src | |
parent | 84411d3b83792ca82fd010cc9a7e905e26ce88e5 (diff) |
Allow forcing strict Blueprints when using the new query cost model.
Diffstat (limited to 'searchcore/src')
-rw-r--r-- | searchcore/src/vespa/searchcore/proton/matching/query.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/matching/query.cpp b/searchcore/src/vespa/searchcore/proton/matching/query.cpp index 73e230fff98..70f60ff1c2d 100644 --- a/searchcore/src/vespa/searchcore/proton/matching/query.cpp +++ b/searchcore/src/vespa/searchcore/proton/matching/query.cpp @@ -201,7 +201,7 @@ void Query::optimize(InFlow in_flow, bool sort_by_cost) { _in_flow = in_flow; - auto opts = Blueprint::Options().sort_by_cost(sort_by_cost); + auto opts = Blueprint::Options().sort_by_cost(sort_by_cost).allow_force_strict(sort_by_cost); _blueprint = Blueprint::optimize_and_sort(std::move(_blueprint), in_flow, opts); LOG(debug, "optimized blueprint:\n%s\n", _blueprint->asString().c_str()); } @@ -224,7 +224,7 @@ Query::handle_global_filter(const IRequestContext & requestContext, uint32_t doc } // optimized order may change after accounting for global filter: trace.addEvent(5, "Optimize query execution plan to account for global filter"); - auto opts = Blueprint::Options().sort_by_cost(sort_by_cost); + auto opts = Blueprint::Options().sort_by_cost(sort_by_cost).allow_force_strict(sort_by_cost); _blueprint = Blueprint::optimize_and_sort(std::move(_blueprint), _in_flow, opts); LOG(debug, "blueprint after handle_global_filter:\n%s\n", _blueprint->asString().c_str()); // strictness may change if optimized order changed: |