mirror of
https://github.com/prometheus/prometheus.git
synced 2025-01-12 22:37:27 -08:00
Merge pull request #13799 from machine424/wbl
chore(tsdb): set the wbl to nil as well in DBReadOnly.loadDataAsQuery…
This commit is contained in:
commit
78c0fd2f4d
|
@ -529,9 +529,10 @@ func (db *DBReadOnly) loadDataAsQueryable(maxt int64) (storage.SampleAndChunkQue
|
|||
if err := head.Init(maxBlockTime); err != nil {
|
||||
return nil, fmt.Errorf("read WAL: %w", err)
|
||||
}
|
||||
// Set the wal to nil to disable all wal operations.
|
||||
// Set the wal and the wbl to nil to disable related operations.
|
||||
// This is mainly to avoid blocking when closing the head.
|
||||
head.wal = nil
|
||||
head.wbl = nil
|
||||
}
|
||||
|
||||
db.closers = append(db.closers, head)
|
||||
|
|
Loading…
Reference in a new issue