Open
Description
Describe the bug
nginx_up's name implies that it indicates whether nginx is up or not - not that the scrape was successful, as the documentation for nginx-prometheus-exporter states. As such, this creates an opportunity to confuse users by giving them false negatives - they will believe that nginx is down based on nginx_up
returning 0 - when in reality, nginx returned a perfectly normal HTTP error, which it could have not done if it wasn't up.
To reproduce
Steps to reproduce the behavior:
- Deploy any version of nginx and configure it deliberately to serve any HTTP error for GET /stub_status.
- Deploy nginx-prometheus-exporter and tell it to scrape metrics from that nginx from the usual place.
Expected behavior
If nginx_up's definition were consistent with its name, it would return true. The status of whether a scrape has succeeded, should be described in a different metric.
Your environment
- Version of the Prometheus exporter - 1.4.1
- Version of Docker/Kubernetes - not relevant
- [if applicable] Kubernetes platform (e.g. Mini-kube or GCP) - not relevant
- Using NGINX or NGINX Plus - NGINX 1.26.2