peimanja / artifactory_exporter

JFrog Artifactory Prometheus Exporter written in Go
Apache License 2.0
141 stars 37 forks source link

Some storage metrics can't be determined due to regex mismatch #137

Closed rknightion closed 6 months ago

rknightion commented 6 months ago

Overview of the Issue

Most of the metrics are scraping fine, but in the exporter error log we get:

exporter-1  | time=2024-03-14T17:00:14.974Z level=ERROR msg="The string was not recognized as a known multiplier." artifactory.number.multiplier=""
exporter-1  | time=2024-03-14T17:00:14.974Z level=ERROR msg="There was an issue calculating the value" metric=artifacts err="Could not recognise '; as multiplier"
exporter-1  | time=2024-03-14T17:00:14.974Z level=ERROR msg="The string was not recognized as a known multiplier." artifactory.number.multiplier=""
exporter-1  | time=2024-03-14T17:00:14.974Z level=ERROR msg="There was an issue calculating the value" metric=binaries err="Could not recognise '; as multiplier"
exporter-1  | time=2024-03-14T17:00:14.974Z level=WARN msg="There was an issue calculating the value" metric=filestore err="The string '499.76 GB' does not match '^(?P<tbytes>[[:digit:]]+(?:\\.[[:digit:]]{1,2})?) TB \\((?P<percent>[[:digit:]]{1,2}(?:\\.[[:digit:]]{1,2})?)%\\)$' pattern."
exporter-1  | time=2024-03-14T17:00:14.974Z level=WARN msg="There was an issue calculating the value" metric=filestoreUsed err="The string '4.82 GB (0.96%)' does not match '^(?P<tbytes>[[:digit:]]+(?:\\.[[:digit:]]{1,2})?) TB \\((?P<percent>[[:digit:]]{1,2}(?:\\.[[:digit:]]{1,2})?)%\\)$' pattern."
exporter-1  | time=2024-03-14T17:00:14.974Z level=WARN msg="There was an issue calculating the value" metric=filestoreFree err="The string '494.94 GB (99.04%)' does not match '^(?P<tbytes>[[:digit:]]+(?:\\.[[:digit:]]{1,2})?) TB \\((?P<percent>[[:digit:]]{1,2}(?:\\.[[:digit:]]{1,2})?)%\\)$' pattern."

Reproduction Steps

Run latest version of exporter on Artifactory Pro 7.77.6

Operating system and Environment details

Amazon Linux 2023 with Artifactory Pro 7.77.6

peimanja commented 6 months ago

@rknightion What version of the exporter are you running?

KacperPerschke commented 6 months ago

Thanks for the issue, and logs.

Please try & review #138 .