Skip to content

Conversation

@lcian
Copy link
Member

@lcian lcian commented May 7, 2025

According to https://develop.sentry.dev/sdk/telemetry/traces/span-operations/
span.op is supposed to be high quality and low cardinality, also because it's queryable by EAP.
It makes no sense to set it equal to the span name.
Let's just set it to default for now, this way it's going to be hidden in the UI and only the span name will be shown.
In the future we will try to infer a more meaningful op from span attributes #793

@lcian lcian requested a review from adinauer May 7, 2025 17:35
Copy link
Contributor

@Swatinem Swatinem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you also do the same for the tracing integration? I believe we do the same thing there.

@lcian
Copy link
Member Author

lcian commented May 8, 2025

I'm thinking back about this, it should not be merged, it's actually fine to use span.name.
Unless the span name is generated dynamically, it's going to be low cardinality.
And it's the only way to distinguish different spans when using the Trace Explorer.
If we set everything to default, then we won't be able to group/filter by span op at all.
For example, in the tracing integration this works quite well because when using the instrument macro on a function, the span.op will be the function name.
This is very useful because that way you can group or filter by a specific function.

@lcian lcian closed this May 8, 2025
@lcian lcian deleted the lcian/feat/otel-span-op-default branch May 8, 2025 08:31
@lcian
Copy link
Member Author

lcian commented May 8, 2025

Actually it's possible to query on the span name as well (span.description), so this might make sense, will have to check what the consensus is on this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants