fix(telemetry): improve error logging for custom trace_id generation #8149#8149
fix(telemetry): improve error logging for custom trace_id generation #8149#8149juancarlosjr97 wants to merge 12 commits intoapollographql:devfrom
Conversation
Co-authored-by: Coenen Benjamin <benjamin.coenen@hotmail.com>
|
Thanks for the update @bnjjj. I realised it is wrong PR number, but I have updated it :) |
| - Jaeger | ||
| - Zipkin | ||
|
|
||
| The router follows the [W3C Trace Context specification](https://www.w3.org/TR/trace-context/) for `trace_id` generation and propagation. OpenTelemetry uses 128-bit (32-character hexadecimal) trace IDs as defined in the W3C standard. When working with systems that do not follow this standard, the router provides format conversion options to ensure compatibility. |
There was a problem hiding this comment.
What does "format conversion options" refer to here? i'm not really familiar with this aspect of router telemetry but I don't understand what this means
There was a problem hiding this comment.
I was referring to this section - https://www.apollographql.com/docs/graphos/routing/observability/telemetry/trace-exporters/overview#request-configuration-reference.
The addition to the documentation is to make sure it is clear what the expectation for the trace ID
|
@mergify copy dev @juancarlosjr97 Thanks so much for opening this! Now that it looks like approval is on the horizon, we're going to move this PR over to a direct branch on the repository so the full CI run can happen, including having access to our You will briefly see a new PR show up in the metadata here, and it will preserve your contribution credit! |
✅ Pull request copies have been createdDetails
|
|
Yup! thank you so much for the contribution! Closing in favor of the now merged #8246. |
This pull request improves logging in the
CustomTraceIdPropagatorimplementation by enhancing the error message with additional context about thetrace_idand the error.First MR #7910 closed by GitHub
Logging enhancement:
apollo-router/src/plugins/telemetry/mod.rs: Updated the error logging statement to include thetrace_idand the error details as structured fields, providing more context for debugging.Checklist
Complete the checklist (and note appropriate exceptions) before the PR is marked ready-for-review.
Exceptions
Note any exceptions here
Notes
Footnotes
It may be appropriate to bring upcoming changes to the attention of other (impacted) groups. Please endeavour to do this before seeking PR approval. The mechanism for doing this will vary considerably, so use your judgement as to how and when to do this. ↩
Configuration is an important part of many changes. Where applicable please try to document configuration examples. ↩
A lot of (if not most) features benefit from built-in observability and
debug-level logs. Please read this guidance on metrics best-practices. ↩Tick whichever testing boxes are applicable. If you are adding Manual Tests, please document the manual testing (extensively) in the Exceptions. ↩