java-dogstatsd-client icon indicating copy to clipboard operation
java-dogstatsd-client copied to clipboard

How to provide the timestamp for submitting distribution?

Open adamwrobel-ext-gd opened this issue 1 year ago • 1 comments

DataDog Web API for Distributions is like this: https://docs.datadoghq.com/api/latest/metrics/#submit-distribution-points

points  [array]

Points relating to the distribution point metric. All points must be tuples with timestamp and a list of values (cannot be a string). Timestamps should be in POSIX time in seconds.

However, recordDistributionValue has no place for a timestamp kind of value. How can I do this?

adamwrobel-ext-gd avatar Dec 07 '23 16:12 adamwrobel-ext-gd

Hi!

While it isn't possible to send distributions with a timestamp with statsd, you can do it using the Datadog API client library. You can find an example on the API page.

vickenty avatar Dec 11 '23 12:12 vickenty