mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
lib/storage: optimize /api/v1/status/tsdb
call by skipping all the artificially created tag entries at once
This is a follow-up for b71be42d90
This commit is contained in:
parent
986c12487a
commit
fcaa0c5202
1 changed files with 8 additions and 0 deletions
|
@ -1423,6 +1423,14 @@ func (is *indexSearch) getTSDBStatusWithFiltersForDate(tfss []*TagFilters, date
|
|||
}
|
||||
if isArtificialTagKey(tmp) {
|
||||
// Skip artificially created tag keys.
|
||||
kb.B = append(kb.B[:0], prefix...)
|
||||
if len(tmp) > 0 && tmp[0] == compositeTagKeyPrefix {
|
||||
kb.B = append(kb.B, compositeTagKeyPrefix)
|
||||
} else {
|
||||
kb.B = marshalTagValue(kb.B, tmp)
|
||||
}
|
||||
kb.B[len(kb.B)-1]++
|
||||
ts.Seek(kb.B)
|
||||
continue
|
||||
}
|
||||
if len(tmp) == 0 {
|
||||
|
|
Loading…
Reference in a new issue