Skip to content

feat(otelmux): update http.route attribute to support request.Pattern #7108

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 7 commits into from
Apr 15, 2025

Conversation

flc1125
Copy link
Member

@flc1125 flc1125 commented Apr 2, 2025

see #6919

Although changes have been made, I'm somewhat unsure if this is what we need. 😅

@flc1125 flc1125 requested a review from a team as a code owner April 2, 2025 15:10
@github-actions github-actions bot requested a review from akats7 April 2, 2025 15:12
Copy link

codecov bot commented Apr 2, 2025

Codecov Report

Attention: Patch coverage is 66.66667% with 3 lines in your changes missing coverage. Please review.

Project coverage is 80.9%. Comparing base (ac946ca) to head (c42b7a3).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...trumentation/github.com/gorilla/mux/otelmux/mux.go 66.6% 2 Missing and 1 partial ⚠️
Additional details and impacted files

Impacted file tree graph

@@          Coverage Diff          @@
##            main   #7108   +/-   ##
=====================================
  Coverage   80.9%   80.9%           
=====================================
  Files        204     204           
  Lines      18064   18066    +2     
=====================================
+ Hits       14626   14628    +2     
  Misses      3011    3011           
  Partials     427     427           
Files with missing lines Coverage Δ
...trumentation/github.com/gorilla/mux/otelmux/mux.go 95.6% <66.6%> (+<0.1%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Contributor

@akats7 akats7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unrelated to this PR, but based on that missing test coverage, it might be good to add a test case where GetPathTemplate returns an err, maybe using a path prefix or something

@flc1125
Copy link
Member Author

flc1125 commented Apr 8, 2025

Unrelated to this PR, but based on that missing test coverage, it might be good to add a test case where GetPathTemplate returns an err, maybe using a path prefix or something

I tried to cover this unit test, but because it's somewhat extreme, it's very difficult to trigger the execution that meets this part of the logic for coverage. So, I ignored it for now.

flc1125 added 2 commits April 12, 2025 22:28
…-setup

# Conflicts:
#	CHANGELOG.md
#	instrumentation/github.com/gorilla/mux/otelmux/test/mux_test.go
@flc1125
Copy link
Member Author

flc1125 commented Apr 12, 2025

Ready for merge.

@dmathieu dmathieu merged commit 73e75f6 into open-telemetry:main Apr 15, 2025
27 of 28 checks passed
@flc1125 flc1125 deleted the otelmux-clean-route-setup branch April 15, 2025 14:18
@MrAlias MrAlias added this to the v1.36.0 milestone Apr 24, 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