All Projects → lipanski → datadog-sidekiq

lipanski / datadog-sidekiq

Licence: MIT License
A Rust app to track Sidekiq enqueued & processed jobs in Datadog

Programming Languages

rust
11053 projects
Dockerfile
14818 projects

Projects that are alternatives of or similar to datadog-sidekiq

serverless-lighthouse-template
Run lighthouse audits from headless chrome in lambda.
Stars: ✭ 25 (+78.57%)
Mutual labels:  datadog, datadog-metrics
SwiftDog
This is an (un)official swift library of the datadog API! Many more features to come, but right now it supports sending metrics and events!
Stars: ✭ 26 (+85.71%)
Mutual labels:  datadog, datadog-api
datadog-api-client-python
Python client for the Datadog API
Stars: ✭ 44 (+214.29%)
Mutual labels:  datadog, datadog-api
datadog-actions-metrics
Send GitHub Actions metrics to Datadog
Stars: ✭ 27 (+92.86%)
Mutual labels:  datadog
modern-rails-flash-messages
Modern Rails flash messages - Example App
Stars: ✭ 21 (+50%)
Mutual labels:  sidekiq
datadog monitor2terraform
Import DataDog monitor rule and generate Terraform resource configuration
Stars: ✭ 14 (+0%)
Mutual labels:  datadog
rust-sidekiq
Rust Sidekiq Client
Stars: ✭ 24 (+71.43%)
Mutual labels:  sidekiq
sidekiq alive
Liveness probe for Sidekiq in Kubernetes deployments
Stars: ✭ 142 (+914.29%)
Mutual labels:  sidekiq
limestone-accounts
Boilerplate Rails 5.2 multitenant SaaS application with webpack and Docker integration. Billing is scoped to accounts.
Stars: ✭ 97 (+592.86%)
Mutual labels:  sidekiq
rocketjob
Ruby's missing background and batch processing system
Stars: ✭ 281 (+1907.14%)
Mutual labels:  sidekiq
heroku-datadog-drain-golang
Funnel metrics from multiple Heroku apps into DataDog using statsd.
Stars: ✭ 34 (+142.86%)
Mutual labels:  datadog
sidekiq-prometheus
Public repository with Prometheus instrumentation for Sidekiq
Stars: ✭ 56 (+300%)
Mutual labels:  sidekiq
scaladog
Datadog API client for Scala.
Stars: ✭ 29 (+107.14%)
Mutual labels:  datadog
passenger-datadog-monitor
Golang application for reporting Phusion Passenger stats to DataDog via statsD
Stars: ✭ 15 (+7.14%)
Mutual labels:  datadog
auth0-instrumentation
The goal of this package is to make it easier to collect information about our services through logs, metrics and error catching.
Stars: ✭ 18 (+28.57%)
Mutual labels:  datadog
sidecloq
Recurring / Periodic / Scheduled / Cron job extension for Sidekiq
Stars: ✭ 81 (+478.57%)
Mutual labels:  sidekiq
road-to-orleans
This repository illustrates the road to orleans with practical, real-life examples. From most basic, to more advanced techniques.
Stars: ✭ 55 (+292.86%)
Mutual labels:  datadog
scott
💼 The Podcast Regional Manager
Stars: ✭ 21 (+50%)
Mutual labels:  sidekiq
rails async migrations
Asynchronous support for ActiveRecord::Migration
Stars: ✭ 56 (+300%)
Mutual labels:  sidekiq
sidekiq-merger
Merge Sidekiq jobs
Stars: ✭ 49 (+250%)
Mutual labels:  sidekiq

datadog-sidekiq

A Rust app to track Sidekiq enqueued & processed jobs in Datadog.

Metrics

Two metrics will be made available in Datadog:

  • sidekiq.enqueued: the amount of enqueued jobs at one point in time
  • sidekiq.processed: the amount of processed jobs between two consequent polling intervals

Consider using the TAGS environment variable to specify your data sources.

Usage

Grab the latest binary from the release section or build it from source.

Configure the monitor via environment variables:

# [Required] The Datadog API key
DD_API_KEY=xxx

# [Required] The full Redis URL (including the port and database number)
REDIS_URL=redis://localhost:6379/0

# [Optional] The Redis namespace to use
REDIS_NAMESPACE=some:namespace

# [Optional] The polling interval in seconds (defaults to 60 seconds)
INTERVAL=60

# [Optional] A comma-separated list of tags
TAGS=application:xxx,environment:yyy,hello:world

# [Optional] The log level: either "error" or "info" (defaults to no logging)
RUST_LOG=error

Run the binary:

datadog-sidekiq

Or run it in the background:

datadog-sidekiq &

If that's not enough, consider using a supervisor (Systemd, runit, Monit, immortal etc.) so you can make sure that your monitor will be available even if the system is restarted.

Docker

The app is also provided as a Docker image: https://hub.docker.com/r/lipanski/datadog-sidekiq

Build from source

Install Rust (latest stable version should be fine).

Clone the project, enter the project directory and run:

cargo build --release

Alternative

Another way to track Sidekiq metrics in Datadog is by using the Datadog Redis integration. There are some drawbacks though and I haven't tried it out myself.

Fetching the amount of processed jobs is as easy as querying [namespace]:stat:processed, but fetching the amount of enqueued jobs is a bit more complicated. First you need to query the names of all your queues - SMEMBERS [namespace]:queues - and for each one of these names you'll need to run LLEN [namespace]:queue:[name] and sum up the results. Ideally you should pipeline these calls, just like Sidekiq does and just like datadog-sidekiq does.

If you're interested in only one queue or just a couple, using the Datadog Redis integration might do the job. If you want a more dynamic solution, give a try to datadog-sidekiq :)

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].