rycus86 / prometheus_flask_exporter

Prometheus exporter for Flask applications
https://pypi.python.org/pypi/prometheus-flask-exporter
MIT License
634 stars 162 forks source link

Default metrics disappeared #133

Open kr886q opened 2 years ago

kr886q commented 2 years ago

I had it setup and connected to prometheus and saw all of the default metrics for 6 different services I am running. I stopped and then started one of the services, and now the only metric that shows up is flask_exporter_info.

I looked in the logs of the services and havent seen anything. Also flask_exporter_info is reporting 1

not sure where else to look to debug.

kr886q commented 2 years ago

flask_http_request_duration_seconds_bucket{le="0.005",method="GET",path="/favicon.ico",status="404"} 3.0

before it was saying status=200, and not sure where this favicon.ico path is coming from

kr886q commented 2 years ago

Okay so endpoints only appear AFTER using them. As for the favicon path I have no idea where thats coming from. Could be the package it self or a blueprint or somewhere else i haven't considered

rycus86 commented 2 years ago

Hey @kr886q - yes, the metrics are not initialized by itself, they appear when you increment a counter, or a histogram receives a measurement, etc.

As for the favicon path I have no idea where thats coming from.

That's usually something the browsers request, perhaps you opened one of the endpoints in the browser to check it? (maybe the metrics endpoint?)