Krinkle added a comment.
It's not documented to my knowledge, but it is a pattern that is followed quite consistently throughout our software and elsewhere in the industry as relating to how StatsD, Graphite and Prometheus are used. Metrics follow a left-to-right hierarchy. In Prometheus this is done with underscores, in StatsD this is done with dots. There is generally one main segment at the start for the overal service or component, then a segment for the metric being measured, and then labels (Prometheus), hash tags (dogstatsd), or subcomponents (statsd/Graphite). The labels/subcomponents should only be used to represent subslices of the same metric, not to create entirely different metrics. So, for example, you would have `foo_bar_request_count.wiki` and `foo_bar_request_size.wiki` and not `foo_bar_request.wiki.request_count` and `foo_bar_request.wiki .request_size. This is also reflected on https://prometheus.io/docs/practices/naming/, because incompatible data structures would otherwise clash and result in non-sensical visualisations when later segments are left out of the query with a wildcard. This ensures maxium benefit of the wider ecosystem through Grafana, such as autocompletion, wildcard queries, and templates. And also reduces chances of conflicts with unrelated metrics clashing in the same timeseries database directory. Remember that for Graphite, each dot-component is a subdirectory on disk where a file is stored, so `enwiki.wikibase.client.scribunto.wikibase.getEntityStatements.cache_miss` gets stored in `/var/lib/carbon/enwiki/wikibase/client/scribunto/wikibase/getEntityStatements/cache_miss/rate.wsp`, for example. TASK DETAIL https://phabricator.wikimedia.org/T292601 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Krinkle Cc: Lucas_Werkmeister_WMDE, Krinkle, Aklapper, Invadibot, maantietaja, Akuckartz, Nandana, lucamauri, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, Vali.matei, _jensen, rosalieper, Scott_WUaS, Wikidata-bugs, aude, Addshore, Mbch331
_______________________________________________ Wikidata-bugs mailing list -- wikidata-bugs@lists.wikimedia.org To unsubscribe send an email to wikidata-bugs-le...@lists.wikimedia.org