Description
What are you trying to achieve?
The motivation for this change is to try to help backends/processing of trace data. If we add a "timestamp" as the first 32-bits into the generated trace-id, it will ensure that trace data (full traces) are generated (sent to the backend) in a "pseudo" order. The order cannot be guaranteed, but it is still an improvement for different backends (stores) to write events in a more deterministic order than completely random.
What did you expect to see?
A change to the default trace-id generator that specifies that the trace-id should have the first 32-bits as timestamp.
Additional context.
- This will be a backwards compatible change since the trace-id is right now consider to be opaque.
- For backends that do not work well with this a simple deterministic "hash" of the trace-id (shuffle bits is enough) can be used to avoid ordering. Unfortunately the opposite cannot be achieved, so it will help to include the timestamp from the source.
Add any other context about the problem here. If you followed an existing documentation, please share the link to it.
See AWS X-ray definition of the trace-id:
https://docs.aws.amazon.com/xray/latest/devguide/xray-api-sendingdata.html
The suggestion is not to follow that model exactly but just to encode the same "timestamp" as the left most 8 hex bytes of the trace-id.
Activity