prometheus/storage
Justin Lei 8ef7dfdeeb
Add a chunk size limit in bytes (#12054)
Add a chunk size limit in bytes

This creates a hard cap for XOR chunks of 1024 bytes.

The limit for histogram chunk is also 1024 bytes, but it is a soft limit as a histogram has a dynamic size, and even a single one could be larger than 1024 bytes.

This also avoids cutting new histogram chunks if the existing chunk has fewer than 10 histograms yet. In that way, we are accepting "jumbo chunks" in order to have at least 10 histograms in a chunk, allowing compression to kick in.

Signed-off-by: Justin Lei <justin.lei@grafana.com>
2023-08-24 15:21:17 +02:00
..
remote Add a chunk size limit in bytes (#12054) 2023-08-24 15:21:17 +02:00
buffer.go Add a chunk size limit in bytes (#12054) 2023-08-24 15:21:17 +02:00
buffer_test.go Merge pull request #12264 from rabenhorst/sample-ring-iterator-mixed-histograms-fix 2023-04-20 16:58:18 +02:00
fanout.go style: Replace else if cascades with switch 2023-04-19 17:22:31 +02:00
fanout_test.go lint: Adjust to the lint warnings raised by current versions of golint-ci 2023-04-19 17:10:10 +02:00
generic.go Move packages out of deprecated pkg directory 2021-11-09 08:03:10 +01:00
interface.go lint: Adjust to the lint warnings raised by current versions of golint-ci 2023-04-19 17:10:10 +02:00
lazy.go tsdb: Added ChunkQueryable implementations to db; unified MergeSeriesSets and vertical to single struct. (#7069) 2020-07-31 16:03:02 +01:00
memoized_iterator.go Make MemoizedSeriesIterator not implement chunkenc.Iterator 2023-05-03 12:45:39 -07:00
memoized_iterator_test.go Make MemoizedSeriesIterator not implement chunkenc.Iterator 2023-05-03 12:45:39 -07:00
merge.go style: Replace else if cascades with switch 2023-04-19 17:22:31 +02:00
merge_test.go Add a chunk size limit in bytes (#12054) 2023-08-24 15:21:17 +02:00
noop.go Move packages out of deprecated pkg directory 2021-11-09 08:03:10 +01:00
secondary.go Move packages out of deprecated pkg directory 2021-11-09 08:03:10 +01:00
series.go Add a chunk size limit in bytes (#12054) 2023-08-24 15:21:17 +02:00
series_test.go Add a chunk size limit in bytes (#12054) 2023-08-24 15:21:17 +02:00