-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Project: Send trace origin #14
Comments
Is there something like this in OTEL? |
@HazAT, I don't think so. When I wrote the RFC getsentry/rfcs#73, I checked the OTEL spec and didn't find anything similar, but I could be wrong as I'm not that familiar with the spec. @AbhiPrasad, as you quote OTEL regularly, do you know if something like the trace orign exists? I guess not cause you would have brought it up in getsentry/rfcs#73. There is a somewhat similar HTTP header origin I used as a bit of inspiration for trace origin. |
@philipphofmann Sentry's OpenTelemetry integrations take OpenTelemetry spans and create Sentry transactions/spans for these in a SpanProcessor. It's hard to tell where those spans came from in these cases though. Were they created automatically by OpenTelemetry or do those spans correspond to spans that users of the OpenTelemetry SDK have instrumented manually? Since we're one step removed from the instrumentation, I'm not sure how we determine this. Has this been solved in any of the existing SDK implementations of Trace Origin already? |
FYI this is now released in v7.66.0 of the JS SDK! |
@jamescrosswell, sorry for the late reply. I was on parental leave for two months. As far as I know, no existing SDK has solved the problem with OpenTelemetry integrations. Could you let me know if you've already solved this problem? If not, I can have a look and add some context to the develop docs. |
Hi @philipphofmann, no problem. No I haven't/can't see a solution to this. About the best I can think of is that in addition to Manual and Automatic, we add Unknown as a possible value... and in the case of OpenTelemetry instrumented spans, these would always have |
@jamescrosswell, the OpenTelemetry instrumented spans should have a span operation, and when creating these spans, we know they stem from OpenTelemetry. Ideally, we should be able to do something like |
Hm, OK thanks @philipphofmann. In the .NET implementation of OpenTelemetry, spans basically start out as an Activitiy and Activities do have an OperationName... however this can be set even for spans that are instrumented manually. We could check to see if the OperationName corresponded to a value that would be used by automatic instrumentation, as long as we could get a list of all the values that might be set for this via automatic instrumentation. I'm not sure if such a list exists anywhere. The semantic conventions documentation talks about keys for all sorts of attributes. I think lots of those are used in the Did you have a specific set of Operation Names in mind that you'd seen somewhere? |
Trace origin uses the category of span operations. When you create spans from OTel, you must extract span operations, which also need to have a span category. Looking at the bunch of C# constants I would say you could pick the first part of these constants. For example, |
We can definitely build that, yes. I'll trust your guidance in terms of whether it's doing what we want or not 👍🏻 |
That's great.
I think the best is you tag me in your PR and I will give you a green light if it LGTM, @jamescrosswell. |
@philipphofmann i am moving this back to planning Can we update this epic with which SDKs have done this already? Is there a way we can check which sdks are sneing it correctly? Via looker for example Then track the remaining SDKs so we can try to close this project |
@smeubank, thanks, for following up on this. You can check this Looker board. I updated the task lists above. |
Description
Trace origin indicates what created a trace or a span. Not all traces and spans contain enough information to tell whether the user or what precisely in the SDK created it. Origin solves this problem. Origin can be sent with the trace context or spans. The SDKs must set this value automatically. It is not expected to be set manually by users. For more information, visit the develop docs. If the spec needs further clarification, you can ping @philipphofmann.
As origin for trace context and spans is optional, every SDK can decide whether to start sending origin for everything or just selected transactions and spans. This issue is important for internal data analysis to understand the quality of our traces; see internal Notion doc.
Project Overview
Web Frontend SDKs
Web Backend SDKs
Mobile SDKs
GDX SDKs
The text was updated successfully, but these errors were encountered: