grafana / x-ray-datasource

AWS X-Ray data source
Apache License 2.0
35 stars 12 forks source link

Convert OpenTelemetry trace id to X-Ray trace id #184

Open rapphil opened 1 year ago

rapphil commented 1 year ago

What is my problem?

In an application that uses OpenTelemetry and generate exemplars and traces, the trace id will be presented in the form of a 128 bit hex string.

image

However the X-Ray trace id format is different: https://docs.aws.amazon.com/xray/latest/devguide/xray-api-sendingdata.html#xray-api-traceids

Nonetheless OpenTelemetry trace ids and X-Ray trace ids are compatible, because both can be stored as a 128 bit integer.

What is the proposed solution?

This plugin should try to automatically convert from OpenTelemetry trace ids to X-Ray trace ids when you click in the button in the dialog from the image above.

This can be an optin feature.

fridgepoet commented 1 year ago

Hey @rapphil thanks, a conversion sounds like it could be useful.

What part of the X-ray plugin has the button in your screenshot?

nakedible-p commented 4 months ago

As an additional information for this – the AWS X-Ray console automatically allow searches with the X-Ray trace id format and the OpenTelemetry (W3C) trace id format. So now it's only Grafana which doesn't do this.