-
Notifications
You must be signed in to change notification settings - Fork 896
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
BREAKING: Change span statuses for gRPC server spans #3333
BREAKING: Change span statuses for gRPC server spans #3333
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.
LGTM, with one minor comment remaining.
@tigrannajaryan Any opinion on getting this merged for the upcoming April Release? |
I think we can merge. |
@pellared can you resolve the conflicts? |
@tigrannajaryan @carlosalberto Done. The PR is ready to be merged 😉 |
…3333) Fixes open-telemetry#3110 ## Changes The idea behind the PR is to make the spam statuses gRPC convention similar to HTTP semantic conventions. The gRPC statuses -> HTTP status codes mapping is not anywhere strictly defined. However, there is are some approximations which can be found: - grpc/grpc@bb04e07#diff-c94ff143c8f378e6925a985fa18528a8254a6d7fc34bc855e1de13f1e7f3e464 - https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto I got confused if we should treat `INTERNAL` as `Error` for `SpanKind.SERVER` because of: - https://github.com/grpc/grpc/blob/master/doc/http-grpc-status-mapping.md - https://github.com/grpc/grpc-go/blob/a02aae6168aa683a1f106e285ec10eb6bc1f6ded/internal/transport/handler_server.go#L90C8-L92 - https://github.com/grpc/grpc-go/blob/a02aae6168aa683a1f106e285ec10eb6bc1f6ded/internal/transport/http_util.go#L73 On the other hand, [the description](https://github.com/grpc/grpc/blob/master/doc/statuscodes.md) of `INTERNAL` says: > Internal errors. This means that some invariants expected by the underlying system have been broken. This error code is reserved for serious errors. Therefore, I decided to leave it as `Error`. Also because this is backwards compatible (at least for this gRPC status). --------- Co-authored-by: Tyler Yahn <MrAlias@users.noreply.github.com>
Fixes #3110
Changes
The idea behind the PR is to make the spam statuses gRPC convention similar to HTTP semantic conventions.
The gRPC statuses -> HTTP status codes mapping is not anywhere strictly defined.
However, there is are some approximations which can be found:
I got confused if we should treat
INTERNAL
asError
forSpanKind.SERVER
because of:On the other hand, the description of
INTERNAL
says:Therefore, I decided to leave it as
Error
. Also because this is backwards compatible (at least for this gRPC status).