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 trying to figure out, can I use the Otel's generated trace ID as something that you can bind to an "operation" in a business context. My concern is that the Otel's trace ID is not suitable for that. I also know about UUID (https://www.rfc-editor.org/rfc/rfc4122) which seems more serious for generating IDs.
Would you not recommend to use Trace ID for something outside of "telemetry"?
Hi @smthlow!
What you are describing is not what the Trace ID is intended for. It is based on the W3C TraceContext specification, which you can read up more on https://w3c.github.io/trace-context/.
Note that while both a UUID and a Trace ID contain of 128 bits, the TraceContext specification only imposes a SHOULD requirement for its randomness, and for only 56 of the bits a MUST requirement for randomness exists, if the random flag is set.
See https://w3c.github.io/trace-context/#trace-id and https://w3c.github.io/trace-context/#randomness-of-trace-id in particular.
Since this lower entropy increases the risk of collisions, it would be safer to rely on UUIDs, but you might still find the 56 bits of entropy acceptable for your application.
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
-
My question is vague. I read that the trace ID is 128 bit (https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/overview.md). Does this mean that this is enough permutations to be sure, it's not gonna generate the same trace ID ever?
I'm trying to figure out, can I use the Otel's generated trace ID as something that you can bind to an "operation" in a business context. My concern is that the Otel's trace ID is not suitable for that. I also know about UUID (https://www.rfc-editor.org/rfc/rfc4122) which seems more serious for generating IDs.
Would you not recommend to use Trace ID for something outside of "telemetry"?
Can you comment anything on that? Thank you.
Beta Was this translation helpful? Give feedback.
All reactions