apm-agent-python
apm-agent-python copied to clipboard
Public API for metrics
We should create some public API interfaces for dealing with metrics.
Currently, to create a histogram metric, a user has to fetch the Client object and then do something like this:
metricset = MetricsSet(MetricsRegistry(elasticapm_client))
hist = metricset.histogram("x", buckets=[1, 10, 100])
Since we're moving away from dealing directly with the Client object where possible, we can condense this down to a single public API call that abstracts most of the details away.