lib/logstorage: proper exit during block search (#5400)

This commit is contained in:
noodles2hg 2024-02-01 20:11:05 +08:00 committed by GitHub
parent 333bda8702
commit cafd6f08b3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -409,7 +409,9 @@ func (p *part) searchByTenantIDs(so *searchOptions, bhss *blockHeaders, workCh c
if so.minTimestamp > th.maxTimestamp || so.maxTimestamp < th.minTimestamp {
continue
}
scheduleBlockSearch(bh)
if !scheduleBlockSearch(bh) {
return
}
}
if len(bhs) == 0 {
break