From ff71b98439681979f0ea297f0c94290428df5d97 Mon Sep 17 00:00:00 2001 From: Nick Pillitteri <56quarters@users.noreply.github.com> Date: Tue, 29 Oct 2024 10:48:38 -0400 Subject: [PATCH] chore: Update to latest thanos-io/objstore commit (#9768) Specifically, pulls in https://github.com/thanos-io/objstore/pull/153 which fixes timing for get operations. --- go.mod | 2 +- go.sum | 4 ++-- vendor/github.com/thanos-io/objstore/CHANGELOG.md | 1 + vendor/github.com/thanos-io/objstore/objstore.go | 4 ++-- vendor/modules.txt | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/go.mod b/go.mod index 527af3f352..282f6d8af6 100644 --- a/go.mod +++ b/go.mod @@ -74,7 +74,7 @@ require ( github.com/okzk/sdnotify v0.0.0-20240725214427-1c1fdd37c5ac github.com/prometheus/procfs v0.15.1 github.com/shirou/gopsutil/v4 v4.24.9 - github.com/thanos-io/objstore v0.0.0-20241024120700-168679cbbf20 + github.com/thanos-io/objstore v0.0.0-20241028150459-cfdd0e50390d github.com/twmb/franz-go v1.17.1 github.com/twmb/franz-go/pkg/kadm v1.13.0 github.com/twmb/franz-go/pkg/kfake v0.0.0-20241015013301-cea7aa5d8037 diff --git a/go.sum b/go.sum index 8a321430d7..f11d67a9e4 100644 --- a/go.sum +++ b/go.sum @@ -919,8 +919,8 @@ github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8 github.com/subosito/gotenv v1.4.1/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= github.com/tencentyun/cos-go-sdk-v5 v0.7.40 h1:W6vDGKCHe4wBACI1d2UgE6+50sJFhRWU4O8IB2ozzxM= github.com/tencentyun/cos-go-sdk-v5 v0.7.40/go.mod h1:4dCEtLHGh8QPxHEkgq+nFaky7yZxQuYwgSJM87icDaw= -github.com/thanos-io/objstore v0.0.0-20241024120700-168679cbbf20 h1:NmVMYAsXPnj9zRG5dDj0SGqrHfbs/1parMRZTvwB8YE= -github.com/thanos-io/objstore v0.0.0-20241024120700-168679cbbf20/go.mod h1:/ZMUxFcp/nT6oYV5WslH9k07NU/+86+aibgZRmMMr/4= +github.com/thanos-io/objstore v0.0.0-20241028150459-cfdd0e50390d h1:k+SLTP1mjNqXxsCiq4UYeKCe07le0ieffyuHm/YfmH8= +github.com/thanos-io/objstore v0.0.0-20241028150459-cfdd0e50390d/go.mod h1:/ZMUxFcp/nT6oYV5WslH9k07NU/+86+aibgZRmMMr/4= github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= diff --git a/vendor/github.com/thanos-io/objstore/CHANGELOG.md b/vendor/github.com/thanos-io/objstore/CHANGELOG.md index 75cbd83411..d2b1aaabda 100644 --- a/vendor/github.com/thanos-io/objstore/CHANGELOG.md +++ b/vendor/github.com/thanos-io/objstore/CHANGELOG.md @@ -13,6 +13,7 @@ We use *breaking :warning:* to mark changes that are not backward compatible (re - [#145](https://github.com/thanos-io/objstore/pull/145) Include content length in the response of Get and GetRange. ### Fixed +- [#153](https://github.com/thanos-io/objstore/pull/153) Metrics: Fix `objstore_bucket_operation_duration_seconds_*` for `get` and `get_range` operations. - [#117](https://github.com/thanos-io/objstore/pull/117) Metrics: Fix `objstore_bucket_operation_failures_total` incorrectly incremented if context is cancelled while reading object contents. - [#115](https://github.com/thanos-io/objstore/pull/115) GCS: Fix creation of bucket with GRPC connections. Also update storage client to `v1.40.0`. - [#102](https://github.com/thanos-io/objstore/pull/102) Azure: bump azblob sdk to get concurrency fixes. diff --git a/vendor/github.com/thanos-io/objstore/objstore.go b/vendor/github.com/thanos-io/objstore/objstore.go index 5bce3ef660..62f1c655db 100644 --- a/vendor/github.com/thanos-io/objstore/objstore.go +++ b/vendor/github.com/thanos-io/objstore/objstore.go @@ -573,7 +573,7 @@ func (b *metricBucket) Get(ctx context.Context, name string) (io.ReadCloser, err if !b.metrics.isOpFailureExpected(err) && ctx.Err() != context.Canceled { b.metrics.opsFailures.WithLabelValues(op).Inc() } - b.metrics.opsDuration.WithLabelValues(op).Observe(float64(time.Since(start))) + b.metrics.opsDuration.WithLabelValues(op).Observe(time.Since(start).Seconds()) return nil, err } return newTimingReader( @@ -600,7 +600,7 @@ func (b *metricBucket) GetRange(ctx context.Context, name string, off, length in if !b.metrics.isOpFailureExpected(err) && ctx.Err() != context.Canceled { b.metrics.opsFailures.WithLabelValues(op).Inc() } - b.metrics.opsDuration.WithLabelValues(op).Observe(float64(time.Since(start))) + b.metrics.opsDuration.WithLabelValues(op).Observe(time.Since(start).Seconds()) return nil, err } return newTimingReader( diff --git a/vendor/modules.txt b/vendor/modules.txt index 301443fca5..30fc93c71f 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -1133,7 +1133,7 @@ github.com/stretchr/objx github.com/stretchr/testify/assert github.com/stretchr/testify/mock github.com/stretchr/testify/require -# github.com/thanos-io/objstore v0.0.0-20241024120700-168679cbbf20 +# github.com/thanos-io/objstore v0.0.0-20241028150459-cfdd0e50390d ## explicit; go 1.21 github.com/thanos-io/objstore github.com/thanos-io/objstore/exthttp