[SERVER-73405] Collect telemetry on shard servers for find and agg Created: 27/Jan/23  Updated: 29/Oct/23  Resolved: 08/Feb/23

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

Type: Task Priority: Major - P3
Reporter: Joshua Lapacik (Inactive) Assignee: Ted Tuckman
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-73878 Don't append hashedTelemetryKey to co... Closed
is related to SERVER-74945 Record telemetry for the shards part ... Closed
Assigned Teams:
Query Optimization
Backwards Compatibility: Fully Compatible
Sprint: QO 2023-02-06, QO 2023-02-20
Participants:

 Description   

A new optional field will need to be added to the find and aggregate commands for transmitting the telemetry key (HostAndPort + md5 hash) to mongod. We should update the telemetry store on mongod in the following ways:

  1. The telemetry store key should now be the hash received from mongos.
  2. Certain metrics will be stored on mongos and so no longer need to be stored on mongod
    1. "firstSeenTimestamp"
    2. "lastExecutionMicros"
    3. "execCount"
    4. "queryExecMicros"
    5. "docsReturned"

When mongos receives a command request, it will generate a hash(md5) from the telemetry key, creating a shape ID (HostAndPort of mongos + md5 hash), adding it to the requests sent to mongod, and accumulating the above metrics in the telemetry store at the end of execution.

Note, we should disallow external $telemetry calls (ones not originating from mongos) on shard servers.



 Comments   
Comment by Githook User [ 09/Feb/23 ]

Author:

{'name': 'Benety Goh', 'email': 'benety@mongodb.com', 'username': 'benety'}

Message: SERVER-73405 shut down mongod before exiting early
Branch: master
https://github.com/mongodb/mongo/commit/9951f47ef530f6c1ae04ee365d4f731a126199f6

Comment by Githook User [ 08/Feb/23 ]

Author:

{'name': 'Ted Tuckman', 'email': 'ted.tuckman@mongodb.com', 'username': 'TedTuckman'}

Message: SERVER-73405 Enable shapeId hash for telemetry on mongod
Branch: master
https://github.com/mongodb/mongo/commit/f2a95d46b1d5ba667048a937fd73de43c391f569

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