Skip to content

fix(telemetry): preserve long query durations - #1226

Open
chriswessels wants to merge 1 commit into
graphprotocol:mainfrom
graphops:chris/qos-long-durations
Open

chriswessels wants to merge 1 commit into
graphprotocol:mainfrom
graphops:chris/qos-long-durations

Conversation

@chriswessels

Copy link
Copy Markdown

Query durations are cast to u16 milliseconds before reporting, so a 70-second request is reported as 4,464 ms and sends misleading latency feedback to selection.

Retain milliseconds as u32, matching the existing protobuf fields, and use checked, saturating conversions at the wire and selection-library integer limits. A 70-second request is reported as 70,000 ms; the selection library's u16 input saturates at 65,535 ms. Tests cover boundary values, client/indexer protobuf round trips, and actual selection-feedback messages. No protobuf schema or tag changes are required.

Validation (on this independent branch):

  • cargo +nightly-2026-06-11 fmt --all -- --check
  • cargo +1.95.0 clippy --all-targets --all-features -- -Dwarnings --force-warn deprecated --force-warn dead-code
  • cargo +1.95.0 test

@chriswessels
chriswessels marked this pull request as ready for review October 29, 2026 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant