Replies: 1 comment 1 reply
-
OperationName exists for legacy/back-compat reasons. (Pre-OpenTelemetry days). It should not be used at all in OpenTelemetry. Please share if there are docs showing its usage, so we can fix them. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I was rather suprised to find that if you create an
Activityand set both theOperationName(via the constructor) andDisplayNameproperties, then it is theDisplayNamethat ends up as thenameof the span exported by the OtlpExporter, andOperationNameis not present in the output at all.opentelemetry-dotnet/src/OpenTelemetry.Exporter.OpenTelemetryProtocol/Implementation/Serializer/ProtobufOtlpTraceSerializer.cs
Line 232 in ceebd45
Looking in to this further, I think this is intentional. The
DisplayNameis to all intents and purposes the actual name of the span, whilst theOperationNameis presumably there for doing advanced filtering, enrichment, etc inside the process.I actually came across this when looking at the network tracing spans created by .NET 9.
Example (source)
Experimental.System.Net.Http.ConnectionsExperimental.System.Net.Http.Connections.ConnectionSetupHTTP connection_setup {address}:{port}AFAICT the
Experimental.System.Net.Http.Connections.ConnectionSetupidentifier won't be available in the output at all, and thenamefield will be the much higher cardinalityDisplayName.Is that what everyone expects?
Beta Was this translation helpful? Give feedback.
All reactions