Skip to content

Update Thanos to latest main #4585

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 2 commits into from
Dec 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
* [ENHANCEMENT] Query Frontend: Add setting `-frontend.forward-headers-list` in frontend to configure the set of headers from the requests to be forwarded to downstream requests. #4486
* [BUGFIX] AlertManager: remove stale template files. #4495
* [BUGFIX] Distributor: fix bug in query-exemplar where some results would get dropped. #4582
* [BUGFIX] Update Thanos dependency: compactor tracing support, azure blocks storage memory fix. #4585

## 1.11.0 2021-11-25

Expand Down
7 changes: 2 additions & 5 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ require (
github.com/facette/natsort v0.0.0-20181210072756-2cd4dd1e2dcb
github.com/felixge/fgprof v0.9.1
github.com/fsouza/fake-gcs-server v1.7.0
github.com/go-kit/kit v0.12.0 // indirect
github.com/go-kit/log v0.2.0
github.com/go-openapi/strfmt v0.21.0
github.com/go-openapi/swag v0.19.15
Expand All @@ -32,8 +31,6 @@ require (
github.com/gorilla/mux v1.8.0
github.com/grafana/dskit v0.0.0-20211021180445-3bd016e9d7f1
github.com/json-iterator/go v1.1.12
github.com/lann/builder v0.0.0-20180802200727-47ae307949d0 // indirect
github.com/lann/ps v0.0.0-20150810152359-62de8c46ede0 // indirect
github.com/lib/pq v1.3.0
github.com/minio/minio-go/v7 v7.0.10
github.com/mitchellh/go-wordwrap v1.0.0
Expand Down Expand Up @@ -86,8 +83,8 @@ replace google.golang.org/grpc => google.golang.org/grpc v1.38.0
// We only pin this version to avoid problems with running go get: github.com/thanos-io/thanos@main. That
// currently fails because Thanos isn't merging release branches to main branch, and Go modules system is then
// confused about which version is the latest one. v0.22.0 was released in July, but latest tag reachable from main
// is v0.19.1. We pin version from late september here. Feel free to remove when updating to later version.
replace github.com/thanos-io/thanos v0.22.0 => github.com/thanos-io/thanos v0.19.1-0.20211122085937-de0e3848ff60
// is v0.19.1. We pin version from early December here. Feel free to remove when updating to later version.
Copy link
Contributor

Choose a reason for hiding this comment

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

Question: is the pin still necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanos release tags are still not on the main branch. This replace pattern allowed me to simply put main on this line, and then go mod vendor correctly resolved it to v0.19.1-0.20211122085937-de0e3848ff60.

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks.
The comment above says it's about merging release branches, but this kinda looks like a merge of the release branch: thanos-io/thanos#4738
Did it not work? Not what Go is expecting?

Copy link
Contributor

Choose a reason for hiding this comment

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

That was a squash merge, not merge commit. It didn't make tag v0.23.1 reachable from main branch.

Copy link
Contributor

Choose a reason for hiding this comment

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

I tried to update release process instructions in Thanos at thanos-io/thanos#4770 to hopefully fix this situation in the future.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for filing thanos-io/thanos#4770 @pstibrany!

Did it not work? Not what Go is expecting?

So we can do a go get on a release tag, and it works:

$ go get github.com/thanos-io/[email protected]
$ go mod vendor
$ git diff
...
-       github.com/thanos-io/thanos v0.22.0
+       github.com/thanos-io/thanos v0.24.0-rc.1
-replace github.com/thanos-io/thanos v0.22.0 => github.com/thanos-io/thanos v0.19.1-0.20211208205607-d1acaea2a11a
+// replace github.com/thanos-io/thanos v0.22.0 => github.com/thanos-io/thanos v0.19.1-0.20211208205607-d1acaea2a11a

... I don't know how important it is that we be able to do go get github.com/thanos-io/thanos@main, but that still doesn't work:

$ go get github.com/thanos-io/thanos@main
go: downloading github.com/thanos-io/thanos v0.19.1-0.20211213141611-c7a44e23febe
go get: github.com/thanos-io/thanos@main (v0.19.1-0.20211213141611-c7a44e23febe) requires github.com/thanos-io/[email protected], not github.com/thanos-io/thanos@main (v0.19.1-0.20211213141611-c7a44e23febe)

So I guess we have a few options:

  1. Leave as-is, wait for Add step for merging release branch back to main. thanos-io/thanos#4770.
  2. Remove the replace and the comment, require v0.24.0-rc.1 directly.
  3. Remove the replace and the comment, wait for v0.24.0 and require it directly.

replace github.com/thanos-io/thanos v0.22.0 => github.com/thanos-io/thanos v0.19.1-0.20211208205607-d1acaea2a11a

// Pin aws-sdk to version prior to go-kit update, to reduce the bulk of change.
// Un-pin once Cortex 1.11 is released.
Expand Down
98 changes: 4 additions & 94 deletions go.sum

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion vendor/github.com/google/btree/btree.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

17 changes: 0 additions & 17 deletions vendor/github.com/google/btree/go.mod

This file was deleted.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading