Daniel Kimsey created ZOOKEEPER-4398:
----------------------------------------

             Summary: Namespace zookeeper prometheus metrics
                 Key: ZOOKEEPER-4398
                 URL: https://issues.apache.org/jira/browse/ZOOKEEPER-4398
             Project: ZooKeeper
          Issue Type: Improvement
          Components: metric system, server
            Reporter: Daniel Kimsey


Thank you for adding Prometheus metrics, it's been very helpful in improving 
the observability of our infrastructure. However we are struggling a bit with 
them as is due to the way Zookeeper names it's metrics.

The current Prometheus metrics exposed by Zookeeper are not namespaced (ie 
prefixed) to be zookeeper specific. This makes identifying/exploring the 
metrics in Prometheus challenging. The Prometheus documentation has the 
following suggestion regarding metric naming:

{quote}
...should have a (single-word) application prefix relevant to the domain the 
metric belongs to. The prefix is sometimes referred to as namespace by client 
libraries. For metrics specific to an application, the prefix is usually the 
application name itself. Sometimes, however, metrics are more generic, like 
standardized metrics exported by client libraries. Examples:

    prometheus_notifications_total (specific to the Prometheus server)
    process_cpu_seconds_total (exported by many client libraries)
    http_request_duration_seconds (for all HTTP requests)
{quote}

There are a great number of metrics that are specific not to the JVM but to 
Zookeeper's technology, it would be awesome if those could be prefixed in some 
capacity. Perhaps simply `zk_`. It would make it more clear which of the 
metrics are related to Zookeeper the application.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to