Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-16233

Preprocessing "Prometheus to JSON" step tester fails on multi-entry value.

XMLWordPrintable

      I want to use regexp in "Prometheus to JSON" step, to filter out some

      "Prometheus to JSON" step Parameter:

      node_cpu_seconds_total{cpu=~".*",mode=~"user|system|iowait"}
      

      Tested multi-line value:

      # HELP node_cpu_seconds_total Seconds the cpus spent in each mode.
      # TYPE node_cpu_seconds_total counter
      node_cpu_seconds_total{cpu="0",mode="user"} 108008.07
      node_cpu_seconds_total{cpu="0",mode="idle"} 108008.07
      

       

      cannot convert Prometheus data to JSON: data parsing error at row 3 "node_cpu_seconds_total{cpu="0",mode="user"} 108008...": invalid character '
      ' following metric value
      

      The character it complains for is EOL.
      But it would be more user friendly if it will not fail, but correctly filter out the 4th line (2nd entry) too.

            Unassigned Unassigned
            zalex_ua Oleksii Zagorskyi
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: