Skip to content

Conversation

mateusz-nalepa
Copy link

@mateusz-nalepa mateusz-nalepa commented Sep 29, 2025

Draft for #14768

Metric name: executor.queue.wait.duration
Type: Histogram
Unit: s
Brief: Measures how long a task waits in an executor queue before being executed by a thread

Attributes:

  • thread.name (string, optional): Name of thread that executes the task

Notes:

  • This metric helps identify saturation in thread pools
  • Measurement starts when the task is enqueued to the executor
  • Tasks scheduled with delay (e.g. via ScheduledThreadPoolExecutor) do not trigger metric until they are actually enqueued

@trask
Copy link
Member

trask commented Sep 29, 2025

@mateusz-nalepa can you summarize in the description above the new telemetry that is emitted by this instrumentation?

@mateusz-nalepa
Copy link
Author

@trask done
Please let me know if this description is enough

@trask
Copy link
Member

trask commented Sep 29, 2025

@mateusz-nalepa more I was looking for a description of the metrics from semantic convention perspective

metric name, unit, brief, notes, attributes, etc

@mateusz-nalepa
Copy link
Author

mateusz-nalepa commented Sep 29, 2025

@trask
I've updated description
I was trying my best based on https://opentelemetry.io/docs/specs/semconv/general/metrics/ and https://opentelemetry.io/docs/specs/semconv/http/http-metrics/#metric-httpserverrequestduration
Please let me know if updated description is enough

@trask
Copy link
Member

trask commented Sep 29, 2025

great, thanks! that helps me a lot to be able to review it just from semantic convention perspective

Unit: ms

You'll want to change this to s (see https://github.com/open-telemetry/semantic-conventions/blob/main/docs/general/metrics.md#instrument-units)

Attributes:

  • thread.name (string): Name of thread that executes the task

this will need to be opt-in if you want to capture it, since it could be high cardinality

@mateusz-nalepa
Copy link
Author

@trask fixed
From my perspective, I wasn't expecting this PR to have any review right now, when it's in draft status, so I know, that it will be an amazing journey to work on it!

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.

2 participants