[SERVER-76220] Handle expression context issues in aggregation telemetry key generation Created: 17/Apr/23  Updated: 29/Oct/23  Resolved: 14/Jun/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 7.1.0-rc0

Type: Task Priority: Major - P3
Reporter: Will Buerger Assignee: Will Buerger
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-75596 Stress $queryStats read path for aggr... Closed
Related
related to SERVER-76412 Separate variable binding and error c... Backlog
Assigned Teams:
Query Integration
Backwards Compatibility: Fully Compatible
Sprint: QO 2023-06-12, QO 2023-06-26
Participants:
Linked BF Score: 159

 Description   

We must set up the expression context used in generating the telemetry key so that it (1) includes all necessary resolved namespaces (ex: secondary namespaces used in $lookup or $unionWith stages) and (2) appropriately handles references to variables defined within a let.



 Comments   
Comment by Githook User [ 14/Jun/23 ]

Author:

{'name': 'Will Buerger', 'email': 'will.buerger@mongodb.com', 'username': 'wbuerger46'}

Message: SERVER-76220: Handle let variables and secondary namespaces in aggregation query stats key generation
Branch: master
https://github.com/mongodb/mongo/commit/cf92b0715198556ce64aa93fe1cece2eaee63389

Comment by Charlie Swanson [ 26/Apr/23 ]

Another similar note - in this ticket we could expand the telemetry passthrough coverage to the aggregate directory (see SERVER-76555). If we don't do that as part of this ticket, we'll need another one. cc will.buerger@mongodb.com and davis.haupt@mongodb.com 

Comment by Charlie Swanson [ 26/Apr/23 ]

Just chatted and decided to include all secondary namespaces in an array as part of the query shape: https://docs.google.com/document/d/11vIGnifVooHS-zrjW2cHoz2Px8vsZ8ranaeprDOin0g/edit#heading=h.i1k4oer0rpla. That seems related here - though we could file a separate ticket to add it if this proves tricky or not a good pairing to tackle at once.

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