diff options
-rwxr-xr-x | prometheus.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/prometheus.py b/prometheus.py index da0d24c..9af4de3 100755 --- a/prometheus.py +++ b/prometheus.py @@ -57,6 +57,10 @@ class Prometheus: Gauge('ejabberd_node_s2s_in', 'count of incoming server-to-server connection', registry=registry).set(self._metrics.get_s2s_in()) Gauge('ejabberd_node_s2s_out', 'count of outgoing server-to-server connection', registry=registry).set(self._metrics.get_s2s_out()) + nodename = self._metrics.nodename + Gauge('ejabberd_node_uptime', 'uptime of ejabberd service', ["node"], registry=registry).labels(nodename).set(self._metrics.get_uptime()) + Gauge('ejabberd_node_proccess', 'count of pejabber proccess', ["node"], registry=registry).labels(nodename).set(self._metrics.get_processes()) + labelnames_vhost = ["vhost"] registered_vhosts = Gauge('ejabberd_registered_vhosts', 'count of user per vhost', labelnames_vhost, registry=registry) |