mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-23 20:37:12 +01:00
d134a310f3
Describe Your Changes When I use usePromCompatibleNaming with vmagent to process data that needs to be formatted from different sources such as InfluxDB, I find that it doesn’t work However, it works in vminsert. I found that vminsert uses the HasRelabeling method to determine whether to relabel. ```go func HasRelabeling() bool { pcs := pcsGlobal.Load() return pcs.Len() > 0 || *usePromCompatibleNaming } ``` in vmagent, the decision to relabel is determined only by pcsGlobal.Len() > 0. However, in the applyRelabeling method, the usePromCompatibleNaming logic is also used to determine whether to relabel in the error handling. ```go func (rctx *relabelCtx) applyRelabeling(tss []prompbmarshal.TimeSeries, pcs *promrelabel.ParsedConfigs) []prompbmarshal.TimeSeries { if pcs.Len() == 0 && !*usePromCompatibleNaming { // Nothing to change. return tss } ``` So I think that the logic for determining whether to relabel in vmagent is not as expected. Checklist The following checks are mandatory: [✅]My change adheres [VictoriaMetrics contributing guidelines](https://docs.victoriametrics.com/contributing/). --------- Co-authored-by: Roman Khavronenko <hagen1778@gmail.com> |
||
---|---|---|
.. | ||
common | ||
csvimport | ||
datadogsketches | ||
datadogv1 | ||
datadogv2 | ||
deployment | ||
graphite | ||
influx | ||
multiarch | ||
native | ||
newrelic | ||
opentelemetry | ||
opentsdb | ||
opentsdbhttp | ||
prometheusimport | ||
promremotewrite | ||
remotewrite | ||
static/css | ||
vmimport | ||
main.go | ||
Makefile | ||
README.md | ||
vmagent.png |
See vmagent docs here.
vmagent docs can be edited at docs/vmagent.md.