Closed dsze closed 2 years ago
@dsze i think when adding this feature it would be nice to add a section to the readme that shows how to use it and why its there. when i first started working on this project i also wondered about adding the non-standard extensions but eventually removed them from my pr. at any rate, this is a good way to allow for full flexibility so it'd be great to document why someone would want this (ie the two examples above)
See https://github.com/vthiery/cpp-statsd-client/pull/45 instead. Had to close this PR because it was created off of master
on my fork, making it difficult to update.
Other statsd backends (e.g. Datadog, netdata) support metric types beyond those supported by the original Etsy statsd daemon. For example:
Histograms (type "h") which are like Timers, but with different units.
Dictionaries (type "d") which are like Sets but also record a count for each unique value.
Since these are non-standard, add a
custom()
method, where the metric type is passed in by the caller, assuming that they know the capabilities of the backend they are using.