prometheusbp: add support for native histograms#709
Conversation
69e31fa to
b06a4cd
Compare
|
|
||
| import "time" | ||
|
|
||
| const ( |
There was a problem hiding this comment.
Not a golang expert but I believe we want these to be const?
There was a problem hiding this comment.
If they can be declared as constants, it's definitely preferable.
There was a problem hiding this comment.
there is one service that is overriding the prometheusbp.DefaultLatencyBuckets. maybe remove the Default prefix if these are not intended to be overridden directly.
konradreiche
left a comment
There was a problem hiding this comment.
Looks good to me. What would it look like to test those changes in an existing or new Go test?
|
|
||
| import "time" | ||
|
|
||
| const ( |
There was a problem hiding this comment.
If they can be declared as constants, it's definitely preferable.
|
|
||
| import "time" | ||
|
|
||
| const ( |
There was a problem hiding this comment.
there is one service that is overriding the prometheusbp.DefaultLatencyBuckets. maybe remove the Default prefix if these are not intended to be overridden directly.
Add support for native histograms using the following settings: - NativeHistogramBucketFactor: 1.1 - NativeHistogramMaxBucketNumber: 160 - NativeHistogramMinResetDuration: 1h
5bf74f1 to
af0e328
Compare
86ba4be to
dd13d98
Compare
kylelemons
left a comment
There was a problem hiding this comment.
Looks good to me, but def make sure to sync with the Baseplate team before merging
dd13d98 to
50cda64
Compare
|
CI fix being added in #711 |
50cda64 to
5fbc1b1
Compare
💸 TL;DR
Add support for native histograms using the following settings:
Jira
This changes means that all histograms defined in baseplate.go will now be scraped as native histograms if the service is scraped using the
PrometheusProtoprotocol. This also requires the resulting prometheus instance to be configured to accept native histograms.If the service is scraped using plantext (the default), then the existing classic histograms will be scraped and this change doesn't change anything for the resulting metrics.
NB:
🧪 Testing Steps / Validation
Ran in snoodev, made sure that when namespace was configured to scrape native histograms, native histograms would show up, and classic histograms would still appear if prometheus was not configured to scrape native histograms.
✅ Checks