Bug Report
Describe the bug
The following happens with both prometheus_textfile and prometheus_scrape inputs.
When having untyped metrics, parsing the prometheus text fails when said metrics have negative values.
Example:
# HELP node_zfs_arc_memory_available_bytes kstat.zfs.misc.arcstats.memory_available_bytes
# TYPE node_zfs_arc_memory_available_bytes untyped
node_zfs_arc_memory_available_bytes -8.58914944e+08
fluent-bit outputs:
[error] [input:prometheus_textfile:prometheus_textfile.0] error parsing file prom.txt: 'cmt_untyped_set failed'
To Reproduce
- Put above prometheus text in a file called
prom.txt
- Use the following configuration:
service:
log_level: debug
daemon: off
pipeline:
inputs:
- name: prometheus_textfile
tag: prom
path: prom.txt
scrape_interval: 1
outputs:
- name: stdout
match: '*'
Expected behavior
Metrics to be successfully scraped.
Screenshots
Your Environment
- Version used: 5.0.7
- Configuration: YAML, see above
- Environment name and version: Debian Package on Trixie
- Server type and version: Debian
- Operating System and version: Trixie
- Filters and plugins: prometheus_textfile
Additional context
We are using Fluent Bit to scrape local metrics and push them via Open Telemetry to a central monitoring instance.
When a single metric with above values exist, the whole exporter fails causing our Monitoring to go haywire.
Bug Report
Describe the bug
The following happens with both prometheus_textfile and prometheus_scrape inputs.
When having
untypedmetrics, parsing the prometheus text fails when said metrics have negative values.Example:
fluent-bit outputs:
To Reproduce
prom.txtExpected behavior
Metrics to be successfully scraped.
Screenshots
Your Environment
Additional context
We are using Fluent Bit to scrape local metrics and push them via Open Telemetry to a central monitoring instance.
When a single metric with above values exist, the whole exporter fails causing our Monitoring to go haywire.