[SERVER-83577] CanonicalQuery::encodeKey() ignores Query Settings when deciding between the Classic/SBE strategy Created: 27/Nov/23  Updated: 02/Feb/24

Status: Open
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Minor - P4
Reporter: Catalin Sumanaru Assignee: Backlog - Query Execution
Resolution: Unresolved Votes: 0
Labels: M3
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Query Execution
Operating System: ALL
Sprint: QE 2024-01-22, QE 2024-02-05, QE 2024-02-19
Participants:

 Description   

 

The following method defined on CanonicalQuery does not take into account whether Query Settings have or haven't been set on a particular query. This could lead to scenarios in which the query hash is wrongfully generated as a SBE one, rather than a classic one, potentially leading to undesired and hard to debug scenarios.

CanonicalQuery::QueryShapeString CanonicalQuery::encodeKey() const {
    return (!_forceClassicEngine && _sbeCompatible) ? canonical_query_encoder::encodeSBE(*this)
                                                    : canonical_query_encoder::encodeClassic(*this);
}

 


Generated at Thu Feb 08 06:52:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.