Skip to content
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

Store: Add a few objectives for Store's data touched/fetched amount and sizes #5819

2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ We use *breaking :warning:* to mark changes that are not backward compatible (re

### Changed

- [#5819](https://github.com/thanos-io/thanos/pull/5819) Store: Add a few objectives for Store's data touched/fetched amount and sizes. They are: 50, 95, and 99 quantiles.
Copy link
Collaborator

Choose a reason for hiding this comment

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

I guess this was accidentally put into removed section instead of added?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh, my bad, @matej-g. Fixed in #5919.


## [v0.29.0](https://github.com/thanos-io/thanos/tree/release-0.29) - Release in progress

### Fixed
Expand Down
25 changes: 15 additions & 10 deletions pkg/store/bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,21 +168,25 @@ func newBucketStoreMetrics(reg prometheus.Registerer) *bucketStoreMetrics {
})

m.seriesDataTouched = promauto.With(reg).NewSummaryVec(prometheus.SummaryOpts{
Name: "thanos_bucket_store_series_data_touched",
Help: "How many items of a data type in a block were touched for a single series request.",
Name: "thanos_bucket_store_series_data_touched",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Help: "How many items of a data type in a block were touched for a single series request.",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Objectives: map[float64]float64{0.50: 0.1, 0.95: 0.1, 0.99: 0.001},
}, []string{"data_type"})
m.seriesDataFetched = promauto.With(reg).NewSummaryVec(prometheus.SummaryOpts{
Name: "thanos_bucket_store_series_data_fetched",
Help: "How many items of a data type in a block were fetched for a single series request.",
Name: "thanos_bucket_store_series_data_fetched",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Help: "How many items of a data type in a block were fetched for a single series request.",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Objectives: map[float64]float64{0.50: 0.1, 0.95: 0.1, 0.99: 0.001},
}, []string{"data_type"})

m.seriesDataSizeTouched = promauto.With(reg).NewSummaryVec(prometheus.SummaryOpts{
Name: "thanos_bucket_store_series_data_size_touched_bytes",
Help: "Size of all items of a data type in a block were touched for a single series request.",
Name: "thanos_bucket_store_series_data_size_touched_bytes",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Help: "Size of all items of a data type in a block were touched for a single series request.",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Objectives: map[float64]float64{0.50: 0.1, 0.95: 0.1, 0.99: 0.001},
}, []string{"data_type"})
m.seriesDataSizeFetched = promauto.With(reg).NewSummaryVec(prometheus.SummaryOpts{
Name: "thanos_bucket_store_series_data_size_fetched_bytes",
Help: "Size of all items of a data type in a block were fetched for a single series request.",
Name: "thanos_bucket_store_series_data_size_fetched_bytes",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Help: "Size of all items of a data type in a block were fetched for a single series request.",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Objectives: map[float64]float64{0.50: 0.1, 0.95: 0.1, 0.99: 0.001},
}, []string{"data_type"})

m.seriesBlocksQueried = promauto.With(reg).NewSummary(prometheus.SummaryOpts{
Expand All @@ -200,8 +204,9 @@ func newBucketStoreMetrics(reg prometheus.Registerer) *bucketStoreMetrics {
Buckets: []float64{0.001, 0.01, 0.1, 0.3, 0.6, 1, 3, 6, 9, 20, 30, 60, 90, 120},
})
m.resultSeriesCount = promauto.With(reg).NewSummary(prometheus.SummaryOpts{
Name: "thanos_bucket_store_series_result_series",
Help: "Number of series observed in the final result of a query.",
Name: "thanos_bucket_store_series_result_series",
douglascamata marked this conversation as resolved.
Show resolved Hide resolved
Help: "Number of series observed in the final result of a query.",
Objectives: map[float64]float64{0.50: 0.1, 0.95: 0.1, 0.99: 0.001},
})

m.chunkSizeBytes = promauto.With(reg).NewHistogram(prometheus.HistogramOpts{
Expand Down