otelgrpc: add labeler implementation to allow adding custom attributes on metrics#8135
Closed
vlad-coman-hs wants to merge 2 commits into
Closed
otelgrpc: add labeler implementation to allow adding custom attributes on metrics#8135vlad-coman-hs wants to merge 2 commits into
vlad-coman-hs wants to merge 2 commits into
Conversation
…cs (#1) * Add labeler implementation to allow adding custom attributes on metrics * Separate context keys for client and server metrics * Add labeler support to request/response size metrics * Add tests for the labeler functionality
|
Author
|
Closing this due to the issue mentioned in the description. Will open another PR dealing with this. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Draft PR to address #6026
Implements the Labeler pattern from
otelhttp.Unfortunately, this pattern does not allow us to add dynamic custom attributes on
rpc_server_request_sizedue to the interceptors executing after the request size metric is recorded. I also applied the Labeler's attributes in theInPayloadandOutPayloadphases to have a visual example on what that looks like. Note however that this only adds the custom attributes on therpc_server_response_size,rpc_client_response_sizeandrpc_client_request_sizemetrics.