Child spans have names and all the attributes I add, but transactions don't.
Is this a limitation of the UI? Would it be by design?
Are we supposed to create bogus root spans so that the real span will end up as a child with full name and all the attributes?
#Why don't child transactions generated from OpenTelemetry show a name nor attributes?
66 messages · Page 1 of 1 (latest)
Which SDK is this? How are you setting attributes currently?
browser sdk, talking to nodejs api talking to nodejs worker.
using OpenTelemetry integration, so we only create otel spans with attributes, Sentry converts the first span as a transaction.
if I look at the event breakdown, I see the child transactions and their names,
and if I only open the child transaction, I also see name, and I see Otel attributes,
they just aren't really processed into anything meaningful Sentry specific it seems.
it's the HTTP POST one.
when I expand it, it again has very little info
when I open it, I find all my otel attributes though, but one would expect them to show while viewed in the tree, and certainly it's title.
the same traces sent to e.g Tempo, work fine and as expected, so im wondering if it's a conversion to sentry issue, or a sentry ui issue.
ahhh this is a sentry UI thing
our new trace view needs to display them!
cc @obtuse mason - could we add the OpenTelemetry transaction context to the trace view?
at least display attributes
very glad to hear that. also I would like to see the transaction name instead of the id,
right now spans are way more useful than the (child) transactions are 🙂
fyi I played with putting the contexts.otel.attributes into contexts.trace.data, but it didn't make a difference,
it seems the transaction view is very limited for attributes etc.
yeah we just haven't fully tested everything out for OTEL in the browser given it's generally not recommended from our side
because it's also missing web vitals, resource information
long tasks are also not there
- component tracking from frameworks
transaction name instead of the id
What ID in particular are you referring to? I think the transaction name just inherits from the OTEL span name
yea, that doesn't stop me hehe, but regardless, I miss the data more for child transactions that are on the server
those two default - xxxx, are child transactions, they only show ids, and not the name.
here they do show the names: #1232055515782320199 message
HTTP POST
PickList.PrintLabel
hmm strange it should show the name
do you mind opening a GH isue about that? that feels like a bug https://github.com/getsentry/sentry
also, HTTP POST transaction/span is marked kind: server, and has the http attributes, so I would instead of default - HTTP POST, expect http.server POST url, like the http.client span above it.
thats what Sentry normally does to spans it recognises as http client/server, method, http.url
yea that, works great for spans, but not for (child) transactions
ahh I see what you mean
we should be setting transaction name/op as well though https://github.com/getsentry/sentry-javascript/blob/d7cf6864b29f30b222f41e8578272f84a4e72a5d/packages/opentelemetry-node/src/spanprocessor.ts#L227
this will probably work better in 8.0.0 though
Can’t wait. Battery died and it’s late, will check in the morning, thanks so far!
thanks for trying things out!
I opened a support ticket earlier with exported jsons from my sentry account, but I can have a look for report too
opened a GH issue https://github.com/getsentry/sentry/issues/69483
GitHub
Environment SaaS (https://sentry.io/) Steps to Reproduce create an otel span with name "test1" on frontend, calling an api that creates an otel span with name "test2", attribute...
the sdk for the api is not the @sentry/opentelemetry-node one, but the @sentry/opentelemetry one.
the behaviour is not different with sentry 8.0.0beta3 btw, except that the attributes are no longer in otel.attributes, but just in data.
it makes no difference however for the rendering.
so the new trace view should be rendering trace context for transactions under event.contexts.trace.data
in spans however, that data lives as direct properties
so not data: { }
but: http.client.ip: X
yea, it matters not where it lives
we just haven't done it yet for transactions!
we need unfurling 🙂
great, what about the transaction naming?
a) default - {id} isn't sufficient
b) for spans it looks at the http method, span kind client, and url, and will automatically change the name to http.client {method} {path} which I liked
we just need to figure out why the transaction is not renaming based on http method, but it might be because it's on the browser
its on the api
its a child transaction of the browser transaction, but it's remote api, so should have no bearing
ah yeah okay then for the node service
something we must have missed somewher
oh wait Memory.find is manual instrumentation? Then I guess the SDK can't guess what it should be because there is no http.method set
ah sorry we're talking about it's parent
Memory.Find is great, thats the name I gave it,
the squigly is on the wrong place, it shows the good span, but the problem is the line above it; a transaction
could you link the sentry trace view? feel free to dm it to me
if you're comfortable with me sudoing in to take a look
otherwise np
that's actually a full on http root span, converted to a transaction, but it's treated worse than a span 😛
if I can find it again np
thanks again for all your help!
sure, left you some messages.
browser otel in sentry 8, how? https://github.com/getsentry/sentry-javascript/discussions/7364#discussioncomment-9250887
e.g I don't find the skipOpenTelemetrySetup for Sentry.init in @sentry/vue,
so i'm guessing there's no otel in browser sentry 8 yet?
GitHub
Just like we have for Node: https://github.com/getsentry/sentry-javascript/tree/develop/packages/opentelemetry-node If you would like to see this please leave a comment/reaction to this post! This ...
are otel span links supported? how do they work with Sentry?
they are not supported atm, but we will add support for them soon!