-
Notifications
You must be signed in to change notification settings - Fork 272
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
[Instrumentation.AspNet] pass http.request.method to sampler #2023
base: main
Are you sure you want to change the base?
Conversation
src/OpenTelemetry.Instrumentation.AspNet.TelemetryHttpModule/ActivityHelper.cs
Outdated
Show resolved
Hide resolved
src/OpenTelemetry.Instrumentation.AspNet.TelemetryHttpModule/CHANGELOG.md
Outdated
Show resolved
Hide resolved
src/OpenTelemetry.Instrumentation.AspNet.TelemetryHttpModule/CHANGELOG.md
Outdated
Show resolved
Hide resolved
Co-authored-by: Cijo Thomas <[email protected]>
src/OpenTelemetry.Instrumentation.AspNet.TelemetryHttpModule/CHANGELOG.md
Outdated
Show resolved
Hide resolved
Co-authored-by: Piotr Kiełkowicz <[email protected]>
{ | ||
tags = cachedTagsStorage ??= new KeyValuePair<string, object?>[1]; | ||
string? path = context.Request?.Unvalidated?.Path; | ||
string? method = context.Request?.HttpMethod; |
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.
I think we need to set the normalized value as we do here
If the method is normalized to _OTHER
then should we also include http.request.method_original, that part is not very clear in spec
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.
fixed 34e7fa3
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.
I think setting "HTTP" like the example you sent is the way to go. Keeping the convention.
@cijothomas @Kielek this would be really useful for us.... can we have it available sooner |
src/OpenTelemetry.Instrumentation.AspNet.TelemetryHttpModule/ActivityHelper.cs
Outdated
Show resolved
Hide resolved
@roycald245, one test is failing. |
I had some distractions recently. Will fix as soon as I'm able |
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
- handle http method attributes as in RequestDataHelper.SetHttpMethodTag - fix cashing tags storage - extend tests
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #2023 +/- ##
==========================================
+ Coverage 73.91% 77.32% +3.40%
==========================================
Files 267 15 -252
Lines 9615 366 -9249
==========================================
- Hits 7107 283 -6824
+ Misses 2508 83 -2425
Flags with carried forward coverage won't be shown. Click here to find out more.
|
@roycald245, I have made some direct changes to
Please double check if you are fine with this solution. @cijothomas, could you please review? |
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
Fixes #57287
Changes
Added http.request.method to tags given to sampler
Merge requirement checklist
CHANGELOG.md
files updated for non-trivial changes