-
Notifications
You must be signed in to change notification settings - Fork 283
chore(http/prom): body_data exports BodyDataMetrics
#4186
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
Merged
Merged
Conversation
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
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
this commit introduces an additional layer of telemetry to the inbound proxy's http router. either http and grpc metrics are used, depending upon the policy that authorized a given request. this is based upon #4174, which refactored the request body telemetry middleware to be metrics agnostic. see: * #4165 * #4166 * #4174 * #4127 * #4186 Signed-off-by: katelyn martin <[email protected]>
this structure representing the frame size metrics is shared by the request and response instrumentation. the `body_data::request` and `body_data::response` submodules reëxport this, because the outbound proxy which uses these middleware separately in route-level and backend-level metrics layers. the inbound proxy, however, uses them each in the same place (see #4180), which is ergonomically odd. this commit introduces a top-level `pub use`, exposing this metrics structure from `body_data`, for consumers that instrument request and response bodies in one place. Signed-off-by: katelyn martin <[email protected]>
ae7b1ee to
2a2433e
Compare
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
see #4180. to make way for the use of request body metrics middleware, we use further qualified paths to `body_data::response::NewRecordBodyData`. to be consistent across the board, we apply this change to the request counting middleware as well. NB: this is based upon #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
our metrics layer is generic across an `N`-typed service factory. this commit introduces types aliases that apply `X`-typed extractor parameters to the `linkerd-http-prom` middleware, which are unaware of a concrete metrics extractor. we use this to reduce the complexity of the `layer()` function's type signature. see #4180. NB: based upon #4188, and #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
see #4180. to make way for the use of request body metrics middleware, we use further qualified paths to `body_data::response::NewRecordBodyData`. to be consistent across the board, we apply this change to the request counting middleware as well. NB: this is based upon #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
our metrics layer is generic across an `N`-typed service factory. this commit introduces types aliases that apply `X`-typed extractor parameters to the `linkerd-http-prom` middleware, which are unaware of a concrete metrics extractor. we use this to reduce the complexity of the `layer()` function's type signature. see #4180. NB: based upon #4188, and #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
this commit introduces an additional layer of telemetry to the inbound proxy's http router. either http and grpc metrics are used, depending upon the policy that authorized a given request. this is based upon #4174, which refactored the request body telemetry middleware to be metrics agnostic. see: * #4188 * #4187 * #4186 * #4174 * #4165 * #4166 * #4127 Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
this commit introduces an additional layer of telemetry to the inbound proxy's http router. either http and grpc metrics are used, depending upon the policy that authorized a given request. this is based upon #4174, which refactored the request body telemetry middleware to be metrics agnostic. see: * #4188 * #4187 * #4186 * #4174 * #4165 * #4166 * #4127 Signed-off-by: katelyn martin <[email protected]>
olix0r
approved these changes
Sep 24, 2025
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
see #4180. to make way for the use of request body metrics middleware, we use further qualified paths to `body_data::response::NewRecordBodyData`. to be consistent across the board, we apply this change to the request counting middleware as well. NB: this is based upon #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
see #4180. to make way for the use of request body metrics middleware, we use further qualified paths to `body_data::response::NewRecordBodyData`. to be consistent across the board, we apply this change to the request counting middleware as well. NB: this is based upon #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
our metrics layer is generic across an `N`-typed service factory. this commit introduces types aliases that apply `X`-typed extractor parameters to the `linkerd-http-prom` middleware, which are unaware of a concrete metrics extractor. we use this to reduce the complexity of the `layer()` function's type signature. see #4180. NB: based upon #4188, and #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
see #4180. to make way for the use of request body metrics middleware, we use further qualified paths to `body_data::response::NewRecordBodyData`. to be consistent across the board, we apply this change to the request counting middleware as well. NB: this is based upon #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
our metrics layer is generic across an `N`-typed service factory. this commit introduces types aliases that apply `X`-typed extractor parameters to the `linkerd-http-prom` middleware, which are unaware of a concrete metrics extractor. we use this to reduce the complexity of the `layer()` function's type signature. see #4180. NB: based upon #4188, and #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
this commit introduces an additional layer of telemetry to the inbound proxy's http router. either http and grpc metrics are used, depending upon the policy that authorized a given request. this is based upon #4174, which refactored the request body telemetry middleware to be metrics agnostic. see: * #4188 * #4187 * #4186 * #4174 * #4165 * #4166 * #4127 Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
our metrics layer is generic across an `N`-typed service factory. this commit introduces types aliases that apply `X`-typed extractor parameters to the `linkerd-http-prom` middleware, which are unaware of a concrete metrics extractor. we use this to reduce the complexity of the `layer()` function's type signature. see #4180. NB: based upon #4188, and #4186. Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 24, 2025
this commit introduces an additional layer of telemetry to the inbound proxy's http router. either http and grpc metrics are used, depending upon the policy that authorized a given request. this is based upon #4174, which refactored the request body telemetry middleware to be metrics agnostic. see: * #4188 * #4187 * #4186 * #4174 * #4165 * #4166 * #4127 Signed-off-by: katelyn martin <[email protected]>
cratelyn
added a commit
that referenced
this pull request
Sep 26, 2025
this commit introduces an additional layer of telemetry to the inbound proxy's http router. either http and grpc metrics are used, depending upon the policy that authorized a given request. this is based upon #4174, which refactored the request body telemetry middleware to be metrics agnostic. see: * #4189 * #4188 * #4187 * #4186 * #4174 * #4165 * #4166 * #4127 Signed-off-by: katelyn martin <[email protected]>
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.
this structure representing the frame size metrics is shared by the
request and response instrumentation.
the
body_data::requestandbody_data::responsesubmodules reëxportthis, because the outbound proxy which uses these middleware separately
in route-level and backend-level metrics layers. the inbound proxy,
however, uses them each in the same place (see
#4180), which is ergonomically odd.
this commit introduces a top-level
pub use, exposing this metricsstructure from
body_data, for consumers that instrument request andresponse bodies in one place.
Signed-off-by: katelyn martin [email protected]