-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Update Prometheus to v0.40.1 #5896
Conversation
eba04f4
to
eed380e
Compare
d3e2175
to
0e4556c
Compare
{T: 1587693300000, V: 14.23859649122807}, {T: 1587693400000, V: 15.407017543859647}, {T: 1587693500000, V: 15.915789473684208}, {T: 1587693600000, V: 15.712280701754386}, | ||
{T: 1587690300000, V: 13.652631578947368}, {T: 1587690400000, V: 14.049122807017543}, {T: 1587690500000, V: 13.961403508771928}, {T: 1587690600000, V: 13.617543859649121}, {T: 1587690700000, V: 14.568421052631578}, {T: 1587690800000, V: 14.989473684210525}, | ||
{T: 1587690900000, V: 16.2}, {T: 1587691000000, V: 16.052631578947366}, {T: 1587691100000, V: 15.831578947368419}, {T: 1587691200000, V: 15.659649122807016}, {T: 1587691300000, V: 14.842105263157894}, {T: 1587691400000, V: 14.003508771929823}, | ||
{T: 1587691500000, V: 13.782456140350876}, {T: 1587691600000, V: 13.86315789473684}, {T: 1587691700000, V: 15.270282598474376}, {T: 1587691800000, V: 14.343859649122805}, {T: 1587691900000, V: 13.975438596491227}, {T: 1587692000000, V: 13.399999999999999}, |
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.
Interesting that the values have changed here 🤔
Adjusted querier tests to match expected results that slightly changed because of native histograms
Maybe you know why they have changed because of native histograms?
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 remember having to update the extrapolatedRate
function in the Thanos engine when updating Prometheus to 2.40.1. I was getting small differences related to floating point calculation since they changed the order of divisions/multiplications. It seems like these changes here are also on the last decimal points which could be the reason why the numbers need slight tweaks.
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.
Looks good overall. I wonder if we want to add support for native histograms in the vendored Cortex codebase. AFAIK we only use the query-frontend from Cortex, so maybe adding support there is not high priority.
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.
Thanks for awesome work! 🌟
One small question.
@@ -75,7 +75,14 @@ func (s *Server) ListenAndServe() error { | |||
if err != nil { | |||
return errors.Wrap(err, "server could not be started") | |||
} | |||
return errors.Wrap(toolkit_web.ListenAndServe(s.srv, s.opts.tlsConfigPath, s.logger), "serve HTTP and metrics") | |||
|
|||
flags := &toolkit_web.FlagConfig{ |
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 wonder if we should just import flags from exporter-toolkit
and pass those options. There is https://pkg.go.dev/github.com/prometheus/exporter-toolkit@v0.8.1/web/kingpinflag#AddFlags
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 that would introduce more changes. I can do that in a separate followup PR. WDYT?
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.
Yup, follow-up sounds good!
04a2a46
to
1d24694
Compare
8ab9eb3
to
06079ae
Compare
@GiedriusS I added a test for both querying native histograms through sidecar and writing native histograms to receiver, to make sure there is no unexpected behavior (error for querying and noop for writing): rabenhorst#1 How I understand it: For querying through the sidecar we will get |
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed pkg Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed internal Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Updated weaveworks/common Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed some querier tests and commented out log spam Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed querier test Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Reverted tls integration test Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed TestChunkQueryable Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Implemented pushdownSeriesIterator AtT fn Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed cloudtrace import Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Ran go mod tidy Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> trigger tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
06079ae
to
c4099ba
Compare
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
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.
Thanks for the tests and thorough explanation, I think you are correct 🙇 let's work on native histograms now and further improvements 💪 awesome work! Just a few last nits before merging this. Also, in the CHANGELOG I think we should add an item. Please explicitly note that native histograms are not supported and queries using them will fail with that error just like in the tests 😄
…s to v0.40.7 Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Damn, unlucky - Prometheus busybox sha256 changed 😄 Maybe you can update to the new hash https://quay.io/repository/prometheus/busybox/manifest/sha256:4ee0a8dced91db2c03eb2a69f20e95a41ad9602ebf3e6892b2666c02cf99cc78 so that e2e tests could run? We have a cronjob that periodically updates these but we can be faster in this PR 😄 |
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Done :D |
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.
💪 thanks for your contribution!
* Updated prometheus to v0.40.1 Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed pkg Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed internal Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Updated weaveworks/common Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed some querier tests and commented out log spam Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed querier test Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Reverted tls integration test Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed TestChunkQueryable Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Implemented pushdownSeriesIterator AtT fn Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed cloudtrace import Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Ran go mod tidy Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> trigger tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Uncommented log line Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Removed TODOs and fixed test message Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Updated prom engine Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added missing nil check for delSeriesIterator and comment Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Fixed comment Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Started working on e2e tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added native histograms e2e tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Updated Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added license header to native histogram tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added retry for TestQueryNativeHistograms Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Improved native histogram tests, added changelog and update prometheus to v0.40.7 Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Fixed changelog Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Removed trailing space from changelog Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Ran busy box updater Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
* Updated prometheus to v0.40.1 Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed pkg Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed internal Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Updated weaveworks/common Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed some querier tests and commented out log spam Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed querier test Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Reverted tls integration test Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed TestChunkQueryable Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Implemented pushdownSeriesIterator AtT fn Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Fixed cloudtrace import Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Ran go mod tidy Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> trigger tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Uncommented log line Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Removed TODOs and fixed test message Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Updated prom engine Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added missing nil check for delSeriesIterator and comment Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Fixed comment Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Started working on e2e tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added native histograms e2e tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Updated Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added license header to native histogram tests Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Added retry for TestQueryNativeHistograms Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Improved native histogram tests, added changelog and update prometheus to v0.40.7 Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Fixed changelog Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Removed trailing space from changelog Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> * Ran busy box updater Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com> Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Update Prometheus to v0.40.1 without implementing native histograms.
Changes
chunkenc.Iterator
interface and usechunkenc.ValueType
Verification