querybook icon indicating copy to clipboard operation
querybook copied to clipboard

feat: Added support for sending custom datadog metrics from querybook

Open jij1949 opened this issue 1 year ago • 2 comments

This PR includes the setup of dogstatsd, a python library used for sending metrics to Datadog as well as the creation of a new stats logger, DatadogStatsLogger.

In addition, it includes 5 metrics: celery.active_workers, celery.active_tasks, task.received, task.failures, and task.successes

The first 2 metrics are sent to datadog every 5 seconds by opening a new thread which continuously runs the send_stats_logger_metrics function. The other 3 metrics are triggered by event handlers so they are sent whenever a task is received by a worker, a task fails, or a task succeeds.

jij1949 avatar Dec 20 '23 20:12 jij1949

Datadog is now an optional dependency

jij1949 avatar Jan 22 '24 16:01 jij1949

@czgu can you help to look the PR again?

jczhong84 avatar Feb 25 '24 04:02 jczhong84