mirror of
https://github.com/prometheus/prometheus
synced 2024-12-26 16:43:21 +00:00
Merge pull request #7550 from krasi-georgiev/panic-head-chunk
no panic the head memseries has chunks in it
This commit is contained in:
commit
d6763acd60
@ -2208,10 +2208,8 @@ func (s *memSeries) iterator(id int, isoState *isolationState, chunkDiskMapper *
|
||||
previousSamples += int(d.numSamples)
|
||||
}
|
||||
}
|
||||
// mmappedChunks does not contain the last chunk. Hence check it separately.
|
||||
if len(s.mmappedChunks) < ix {
|
||||
previousSamples += s.headChunk.chunk.NumSamples()
|
||||
} else {
|
||||
|
||||
if s.headChunk != nil {
|
||||
totalSamples += s.headChunk.chunk.NumSamples()
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user