You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm opening this thread to gather experiences, best practices, and recommendations around using HotChocolate together with OpenTelemetry. We’re in the process of improving our observability setup and would love to learn from the community.
What we've noticed so far
While integrating HotChocolate.Diagnostics with OpenTelemetry, we observed:
A high volume of logs when using
HotChocolate.Diagnostics.ActivityScopes.Default
The majority of entries are for ResolveFieldValue, often with durations < 1 ms.
This raises the question: Does logging so many field-level resolve activities indicate something inefficient in our GraphQL queries, or is this just normal behavior?
Potential workaround
We tested suppressing these logs via:
ResolveFieldValue | Scope that encloses the execution of a specific field resolver. (*)
(*): The ResolveFieldValue event is not invoked per default, as it would be too much overhead to execute the event for each resolver used within a query. We have to override the EnableResolveFieldValue property for the execution engine to invoke the event handler.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone!
I'm opening this thread to gather experiences, best practices, and recommendations around using HotChocolate together with OpenTelemetry. We’re in the process of improving our observability setup and would love to learn from the community.
What we've noticed so far
While integrating HotChocolate.Diagnostics with OpenTelemetry, we observed:
Potential workaround
We tested suppressing these logs via:
This significantly reduces noise — but we're unsure whether this is the recommended approach or if it hides valuable insight.
Related issue
In the documentation of HotChocolate & Instrumentation stated (https://chillicream.com/docs/hotchocolate/v15/server/instrumentation#execution-events):
But in the code it says:
graphql-platform/src/HotChocolate/Diagnostics/src/Diagnostics/Listeners/ActivityExecutionDiagnosticListener.cs
Line 29 in 603555e
So this doesn't seem consistent for me :)
Also we have found a relevant GitHub discussion here: #7740 …but would love more community input and real-world experiences.
Questions
Any advice, examples, or thoughts are very welcome!
Thanks in advance 🙏
Beta Was this translation helpful? Give feedback.
All reactions