KEMBAR78
Add support for the `WithMetricAttributesFn` option for otelhttp middlewares by TanishqPorwar · Pull Request #6542 · open-telemetry/opentelemetry-go-contrib · GitHub
Skip to content

Conversation

TanishqPorwar
Copy link
Contributor

add metricAttributesFn to http server handler in otelhttp, for dynamically setting per-request metric attributes

@TanishqPorwar TanishqPorwar requested review from a team and dmathieu as code owners December 29, 2024 20:04
@dmathieu
Copy link
Member

Could you add tests?

@TanishqPorwar
Copy link
Contributor Author

@dmathieu I have added some tests.

@dmathieu dmathieu changed the title add metricAttributesFn to http server handler in otelhttp Add support for the WithMetricAttributesFn option for otelhttp middlewares Jan 6, 2025
TanishqPorwar and others added 2 commits January 6, 2025 14:20
@codecov
Copy link

codecov bot commented Jan 6, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.5%. Comparing base (96acbc0) to head (57dafe0).
Report is 1 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@          Coverage Diff          @@
##            main   #6542   +/-   ##
=====================================
  Coverage   68.5%   68.5%           
=====================================
  Files        200     200           
  Lines      16772   16781    +9     
=====================================
+ Hits       11491   11500    +9     
  Misses      4935    4935           
  Partials     346     346           
Files with missing lines Coverage Δ
instrumentation/net/http/otelhttp/handler.go 92.8% <100.0%> (+0.4%) ⬆️

@dmathieu dmathieu merged commit 6ac9f50 into open-telemetry:main Jan 6, 2025
25 checks passed
@MrAlias MrAlias added this to the v1.34.0 milestone Jan 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants