Skip to content

Commit

Permalink
Revert averaging for overlapping chunks
Browse files Browse the repository at this point in the history
  • Loading branch information
jeschkies committed Jan 24, 2024
1 parent 79afa56 commit 7b3427c
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions pkg/storage/stores/shipper/indexshipper/tsdb/index/chunk.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,6 @@ func (c ChunkMetas) Stats(from, through int64, deduplicate bool) ChunkStats {
for _, cur := range c[1:] {
// Skip chunk if it's a subset of the last one
if cur.MinTime < last.MaxTime && cur.MaxTime <= last.MaxTime {
// Average overlap
overlap := cur.MaxTime - cur.MinTime
lastLen := last.MaxTime - last.MinTime
c[n-1].KB = c[n-1].KB - uint32(float64(overlap)/float64(lastLen)*float64(last.KB)/2) + cur.KB/2
continue
}
c[n] = cur
Expand Down

0 comments on commit 7b3427c

Please sign in to comment.