I would like to expose some metrics to prometheus to track explore the data using grafana. @jcarvalho initially suggested this in Koenkk/zigbee2mqtt-user-extensions#5 and there was another PR by @junosuarez Koenkk/zigbee2mqtt/pull/16905.
This PR is in fact a rough copy past from @junosuarez initial work in the aforementioned PR and I would like to reopen the discussion to add support for Prometheus metrics as an extension for Zigbee2MQTT.
My use case is purely to expose the current state of the various registered devices (state, LQI, battery, temperature, soli humidity, etc) although I'm aware some people would like to have Zigbee metrics from zigbee-herdsman. Either way, I'm happy to start with basics and extend the use cases as needed.
If we move forward, there are a few things we may need to clarifyÇ
[ ] Review what is the approach to install dependencies, in this case prom-client
Other alternatives
I'm aware of other alternatives, specially using MQTT exporters, although I would prefer to have less moving parts as well the possibility of having other internal metrics.
Description
I would like to expose some metrics to prometheus to track explore the data using grafana. @jcarvalho initially suggested this in Koenkk/zigbee2mqtt-user-extensions#5 and there was another PR by @junosuarez Koenkk/zigbee2mqtt/pull/16905. This PR is in fact a rough copy past from @junosuarez initial work in the aforementioned PR and I would like to reopen the discussion to add support for Prometheus metrics as an extension for Zigbee2MQTT.
My use case is purely to expose the current state of the various registered devices (state, LQI, battery, temperature, soli humidity, etc) although I'm aware some people would like to have Zigbee metrics from zigbee-herdsman. Either way, I'm happy to start with basics and extend the use cases as needed.
If we move forward, there are a few things we may need to clarifyÇ
prom-client
Other alternatives
I'm aware of other alternatives, specially using MQTT exporters, although I would prefer to have less moving parts as well the possibility of having other internal metrics.