-
Notifications
You must be signed in to change notification settings - Fork 6
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
Adopt latest semantic conventions #174
Adopt latest semantic conventions #174
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your contribution 🙏
I think your proposal makes sense 👍
@primait/shared-services I think we should double check that datadog is 100% compatible with the "new" (one year old 😆 ) naming
"server.port", | ||
"url.full", | ||
"url.scheme" | ||
] == | ||
attributes |> Map.keys() |> Enum.sort() | ||
|
||
assert {"http.method", "GET"} in attributes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we could maybe start adding comments to attributes that should be deprecated, WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
WDYM? How?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking about simple plain comments like
# deprecated
😆
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So # deprecated
after each old convention in this list?
Lines 22 to 33 in b64102b
@http_method Atom.to_string(Conventions.http_method()) | |
@http_request_method "http.request.method" | |
@http_response_status_code "http.response.status_code" | |
@http_route Atom.to_string(Conventions.http_route()) | |
@http_status_code Atom.to_string(Conventions.http_status_code()) | |
@http_url Atom.to_string(Conventions.http_url()) | |
@net_peer_name Atom.to_string(Conventions.net_peer_name()) | |
@server_address "server.address" | |
@server_port "server.port" | |
@url_full "url.full" | |
@url_scheme "url.scheme" | |
@url_template "url.template" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yep, something like that 🤷
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@\primait/shared-services I think we should double check that datadog is 100% compatible with the "new" (one year old 😆 ) naming
yeah it is
https://docs.datadoghq.com/opentelemetry/schema_semantics/semantic_mapping/
"server.port", | ||
"url.full", | ||
"url.scheme" | ||
] == | ||
attributes |> Map.keys() |> Enum.sort() | ||
|
||
assert {"http.method", "GET"} in attributes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
WDYM? How?
not sure about that page should be read, but I think it's the opposite -.-"
I don't think it does it 'automagically'; my understanding is you should use datadog's conventions and this page simply lists how to map them from opentelemetry conventions; am I wrong? :D |
Datadog does map otel semantic conventions to their own format but it looks like the new http conventions aren't supported yet DataDog/opentelemetry-mapping-go#163
I think considering that datadog and upstream otel libs don't have support for the new spec yet we'd like to have an opt-in flag |
I haven't used Datadog but would this matter as long as the old attributes are still there? This pull request doesn't remove them. It only adds the new ones to allow a seamless migration. |
you're absolutely right, sorry, brain fart @mbusi can we merge? |
This adopts the latest semantic conventions, version 1.26.0, and keeps what's already there.
Notably, this pull request makes the following HTTP client span attributes available:
http.request.method
http.response.status_code
server.address
server.port
url.full
url.scheme
There are no constants available for these yet. open-telemetry/opentelemetry-erlang#733 is currently a draft.
See also this summary of changes and the list of deprecated attributes.
I'll note that the migration guide suggests defining the
OTEL_SEMCONV_STABILITY_OPT_IN
environment variable to allow opting in to the new set. That seems unnecessarily complicated to me but happy to follow that advise if you prefer.I think the simpler approach is this:
http/dup
equivalent)http
equivalent)The benefit of making these available already is that anyone adopting Telepoison today can use the latest conventions already and for existing users, double-writing allows for a seamless migration.