mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-21 14:44:00 +00:00
app/vminsert/influx: properly handle the case when certain labels with empty values are removed by ApplyRelabeling() call
Previously this could lead to `out of range` panic
This commit is contained in:
parent
e4e1cd1de2
commit
8c14ca93fa
1 changed files with 1 additions and 1 deletions
|
@ -105,7 +105,7 @@ func insertRows(db string, rows []parser.Row) error {
|
|||
}
|
||||
labels := ic.Labels
|
||||
if !hasRelabeling {
|
||||
labels = labels[labelsLen : labelsLen+1]
|
||||
labels = labels[len(labels)-1:]
|
||||
}
|
||||
ic.WriteDataPoint(ctx.metricNameBuf, labels, r.Timestamp, f.Value)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue