-
Notifications
You must be signed in to change notification settings - Fork 581
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
otelhttp: set unit on all instruments #4500
Conversation
6516cd5
to
cff1423
Compare
Codecov Report
@@ Coverage Diff @@
## main #4500 +/- ##
=====================================
Coverage 80.9% 80.9%
=====================================
Files 150 150
Lines 10292 10304 +12
=====================================
+ Hits 8327 8339 +12
Misses 1825 1825
Partials 140 140
|
Can you set units for all of the metric instruments? |
@pellared Done. I think the spec and what is actually implemented is not the same thing because the spec talks about compressed payload but the implementation measures uncompressed data read/written by the app. This is probably fine, but perhaps the spec needs to be augmented with metrics for uncompressed data. Also, some description language in the spec seem to be not written grammatically correct (from what I can tell, not a native speaker). |
14124df
to
3649b63
Compare
3649b63
to
da5f92d
Compare
Side note/question: it's really weird that maps are used when just normal fields could be. What is the reason? Map lookup involves computing the hash of the string key, etc and is definitely more work for the CPU vs just a pointer dereference. |
Yeah, I saw this as well and I agree 👍 I created #4502 |
Thank you ❤️
I think the current |
Co-authored-by: Tyler Yahn <[email protected]>
Co-authored-by: Tyler Yahn <[email protected]>
Co-authored-by: Tyler Yahn <[email protected]>
Currently the histogram metric doesn't have units specified. It's good to have them explicitly specified.
The recorded value is actually milliseconds, not microseconds:
opentelemetry-go-contrib/instrumentation/net/http/otelhttp/handler.go
Lines 230 to 233 in bead7e4