Open
Description
Hi everyone!
I have a question about the profile module in the codebase. Specifically, I would like to understand why we use spanId and rootSpanId to correlate profiles with traces in Datadog's dd-trace-java repository.
In my opinion, there are several approaches to correlating profiles with traces:
- Use traceId and spanId to correlate each span with the related profile data.
- Use traceId to correlate the entire trace with the related profile data.
However, I noticed that we use spanId and rootSpanId in the dd-trace-java project. Is there any deeper consideration behind this choice?
I hope to receive your response. Thank you very much!