Skip to content

Commit

Permalink
Merge pull request #77 from andyasp/fix-metricBucket-upload-object-size
Browse files Browse the repository at this point in the history
Fix metricBucket losing object size in Upload
  • Loading branch information
yeya24 authored Sep 21, 2023
2 parents eb06103 + 6175521 commit cac7ba2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ We use *breaking :warning:* to mark changes that are not backward compatible (re
- [#33](https://github.com/thanos-io/objstore/pull/33) Tracing: Add `ContextWithTracer()` to inject the tracer into the context.
- [#34](https://github.com/thanos-io/objstore/pull/34) Fix ignored options when creating shared credential Azure client.
- [#62](https://github.com/thanos-io/objstore/pull/62) S3: Fix ignored context cancellation in `Iter` method.
- [#77](https://github.com/thanos-io/objstore/pull/77) Fix buckets wrapped with metrics from being unable to determine object sizes in `Upload`.

### Added
- [#15](https://github.com/thanos-io/objstore/pull/15) Add Oracle Cloud Infrastructure Object Storage Bucket support.
Expand Down
2 changes: 1 addition & 1 deletion objstore.go
Original file line number Diff line number Diff line change
Expand Up @@ -594,7 +594,7 @@ func (b *metricBucket) Upload(ctx context.Context, name string, r io.Reader) err
b.ops.WithLabelValues(op).Inc()

trc := newTimingReadCloser(
io.NopCloser(r),
NopCloserWithSize(r),
op,
b.opsDuration,
b.opsFailures,
Expand Down

0 comments on commit cac7ba2

Please sign in to comment.