Skip to content

Commit 8c29372

Browse files
authored
Update Thanos to get latest querysharding fix (#4963)
* update Thanos to get latest querysharding fix Signed-off-by: Ben Ye <[email protected]> * update modules Signed-off-by: Ben Ye <[email protected]> Signed-off-by: Ben Ye <[email protected]>
1 parent ce5d1ea commit 8c29372

File tree

7 files changed

+55
-54
lines changed

7 files changed

+55
-54
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ require (
4848
github.com/spf13/afero v1.6.0
4949
github.com/stretchr/testify v1.8.0
5050
github.com/thanos-io/objstore v0.0.0-20221006135717-79dcec7fe604
51-
github.com/thanos-io/thanos v0.27.0-rc.0.0.20221102162214-50b41561b178
51+
github.com/thanos-io/thanos v0.29.1-0.20221111094505-b2badad930d6
5252
github.com/uber/jaeger-client-go v2.30.0+incompatible
5353
github.com/weaveworks/common v0.0.0-20220706100410-67d27ed40fae
5454
go.etcd.io/etcd/api/v3 v3.5.4

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -927,8 +927,8 @@ github.com/thanos-community/galaxycache v0.0.0-20211122094458-3a32041a1f1e h1:f1
927927
github.com/thanos-community/galaxycache v0.0.0-20211122094458-3a32041a1f1e/go.mod h1:jXcofnrSln/cLI6/dhlBxPQZEEQHVPCcFaH75M+nSzM=
928928
github.com/thanos-io/objstore v0.0.0-20221006135717-79dcec7fe604 h1:9dceDSKKsLWNHjrMpyzK1t7eVcAZv9Dp3FX+uokUS2Y=
929929
github.com/thanos-io/objstore v0.0.0-20221006135717-79dcec7fe604/go.mod h1:Vx5dZs9ElxEhNLnum/OgB0pNTqNdI2zdXL82BeJr3T4=
930-
github.com/thanos-io/thanos v0.27.0-rc.0.0.20221102162214-50b41561b178 h1:rZTdKdZyyG+6Yi50mOkRmw7BFmZhdnFr/N+8o+Enadw=
931-
github.com/thanos-io/thanos v0.27.0-rc.0.0.20221102162214-50b41561b178/go.mod h1:odqdxSO+o/UaVgNpdkYYaQUW/JpT7LByXyZmxoe6uoc=
930+
github.com/thanos-io/thanos v0.29.1-0.20221111094505-b2badad930d6 h1:8q0LB3XOhscrqEYU0g5+ekB1ZHERk8tUl1l/y9DbeXA=
931+
github.com/thanos-io/thanos v0.29.1-0.20221111094505-b2badad930d6/go.mod h1:odqdxSO+o/UaVgNpdkYYaQUW/JpT7LByXyZmxoe6uoc=
932932
github.com/themihai/gomemcache v0.0.0-20180902122335-24332e2d58ab h1:7ZR3hmisBWw77ZpO1/o86g+JV3VKlk3d48jopJxzTjU=
933933
github.com/themihai/gomemcache v0.0.0-20180902122335-24332e2d58ab/go.mod h1:eheTFp954zcWZXCU8d0AT76ftsQOTo4DTqkN/h3k1MY=
934934
github.com/tidwall/pretty v0.0.0-20180105212114-65a9db5fad51/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk=

pkg/querier/tripperware/test_shard_by_query_utils.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ sum by (container) (
140140
{
141141
name: "multiple binary expressions with grouping",
142142
expression: `(http_requests_total{code="400"} + on (pod) http_requests_total{code="500"}) / on (cluster, pod) http_requests_total`,
143-
shardingLabels: []string{"cluster", "pod"},
143+
shardingLabels: []string{"pod"},
144144
},
145145
{
146146
name: "histogram quantile",
@@ -161,6 +161,11 @@ sum by (container) (
161161
expression: "increase(sum(http_requests_total) by (pod, cluster) [1h:1m])",
162162
shardingLabels: []string{"cluster", "pod"},
163163
},
164+
{
165+
name: "ignore vector matching with 2 aggregations",
166+
expression: `sum(rate(node_cpu_seconds_total[3h])) by (cluster_id, mode) / ignoring(mode) group_left sum(rate(node_cpu_seconds_total[3h])) by (cluster_id)`,
167+
shardingLabels: []string{"cluster_id"},
168+
},
164169
}
165170

166171
shardableWithoutLabels := []queries{

vendor/github.com/thanos-io/thanos/pkg/promclient/promclient.go

Lines changed: 23 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/thanos-io/thanos/pkg/querysharding/analysis.go

Lines changed: 16 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/github.com/thanos-io/thanos/pkg/querysharding/analyzer.go

Lines changed: 6 additions & 37 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/modules.txt

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)