Merge pull request #11632 from bboreham/improve-bbss

tsdb: improve blockBaseSeriesSet scan
This commit is contained in:
Ganesh Vernekar 2022-12-14 15:05:27 +05:30 committed by GitHub
commit db99fc43e4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -492,10 +492,10 @@ func (b *blockBaseSeriesSet) Next() bool {
if chk.MinTime > b.maxt {
continue
}
if !(tombstones.Interval{Mint: chk.MinTime, Maxt: chk.MaxTime}.IsSubrange(intervals)) {
chks = append(chks, chk)
if (tombstones.Interval{Mint: chk.MinTime, Maxt: chk.MaxTime}.IsSubrange(intervals)) {
continue
}
chks = append(chks, chk)
// If still not entirely deleted, check if trim is needed based on requested time range.
if !b.disableTrimming {