Skip to content
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

Change network.transport from recommended to opt-in in the HTTP semconv #402

Conversation

trask
Copy link
Member

@trask trask commented Oct 13, 2023

Fixes #389

network.transport is typically derivable from network.protocol.version:

  • HTTP 1.0, 1.1, 2 --> tcp
  • HTTP 3 --> udp

so it doesn't provide much value to capture in HTTP semconv.

Changes

Change network.transport from recommended to opt-in in the HTTP semconv.

Merge requirement checklist

@trask trask force-pushed the remove-network-transport-from-http-semconv branch from 587e614 to 0b9c69e Compare October 13, 2023 00:48
@trask trask marked this pull request as ready for review October 13, 2023 00:48
@trask trask requested review from a team October 13, 2023 00:48
Copy link
Member

@mateuszrzeszutek mateuszrzeszutek left a comment

Choose a reason for hiding this comment

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

👍

It was pretty much always skipped anyway:

If not default (tcp for HTTP/1.1 and HTTP/2, udp for HTTP/3).

docs/http/http-spans.md Outdated Show resolved Hide resolved
@Oberon00
Copy link
Member

Oberon00 commented Oct 13, 2023

network.transport is always derivable from network.protocol.version:

Actually this is not true. In Node.js scenarios I think it is not entirely unheard of to communicate with a local HTTP server over Unix domain sockets. We have seen this in the wild with our agents I believe

@lmolkova
Copy link
Contributor

lmolkova commented Oct 13, 2023

Actually this is not true. In Node.js scenarios I think it is not entirely unheard of to communicate with a local HTTP server over Unix domain sockets. We have seen this in the wild with our agents I believe

Looking for net.transport in -js and -js-contrib repos, I don't see HTTP instrumentations using it:

  • http instrumentations set tcp or udp only
  • node:net (IPC) module instrumentation sets pipe or UNIX domain socket. I.e. it'd probably create more spans for the underlying socket if HTTP calls happen over it.

I agree it's a valid concern, but having this attribute outside of HTTP spec and effectively opt-in still works.
Instrumentations can add it later, it would not even be breaking for metrics - from the format of the server.address it's pretty clear it's a unix domain socket and adding transport would not create new time series.

@trask trask changed the title Remove network.transport from HTTP semconv, effectively making it opt-in Change network.transport from recommended to opt-in in the HTTP semconv Oct 16, 2023
@joaopgrassi joaopgrassi merged commit 7680dc8 into open-telemetry:main Oct 17, 2023
8 checks passed
trisch-me pushed a commit to trisch-me/semantic-conventions that referenced this pull request Oct 17, 2023
@trask trask deleted the remove-network-transport-from-http-semconv branch October 14, 2024 21:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Change requirement level of network.transport in HTTP semconv
7 participants