{"id":18865865,"url":"https://github.com/lipanski/datadog-sidekiq","last_synced_at":"2025-06-12T12:38:46.899Z","repository":{"id":146632281,"uuid":"91821735","full_name":"lipanski/datadog-sidekiq","owner":"lipanski","description":"A Rust app to track Sidekiq enqueued \u0026 processed jobs in Datadog ","archived":false,"fork":false,"pushed_at":"2020-01-09T08:54:45.000Z","size":13,"stargazers_count":13,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-14T14:32:16.832Z","etag":null,"topics":["datadog","datadog-api","datadog-metrics","rust","sidekiq"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lipanski.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-05-19T15:48:58.000Z","updated_at":"2023-01-04T21:06:57.000Z","dependencies_parsed_at":null,"dependency_job_id":"204017a7-8eab-4058-b650-9ef6bd424f11","html_url":"https://github.com/lipanski/datadog-sidekiq","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/lipanski/datadog-sidekiq","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipanski%2Fdatadog-sidekiq","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipanski%2Fdatadog-sidekiq/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipanski%2Fdatadog-sidekiq/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipanski%2Fdatadog-sidekiq/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lipanski","download_url":"https://codeload.github.com/lipanski/datadog-sidekiq/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipanski%2Fdatadog-sidekiq/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259466683,"owners_count":22862362,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["datadog","datadog-api","datadog-metrics","rust","sidekiq"],"created_at":"2024-11-08T05:04:51.456Z","updated_at":"2025-06-12T12:38:46.891Z","avatar_url":"https://github.com/lipanski.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# datadog-sidekiq\n\nA Rust app to track Sidekiq enqueued \u0026 processed jobs in Datadog.\n\n## Metrics\n\nTwo metrics will be made available in Datadog:\n\n- `sidekiq.enqueued`: the amount of enqueued jobs at one point in time\n- `sidekiq.processed`: the amount of processed jobs between two consequent polling intervals\n\nConsider using the `TAGS` environment variable to specify your data sources.\n\n## Usage\n\nGrab the latest binary from the [release section](https://github.com/lipanski/datadog-sidekiq/releases) or build it from source.\n\nConfigure the monitor via environment variables:\n\n```bash\n# [Required] The Datadog API key\nDD_API_KEY=xxx\n\n# [Required] The full Redis URL (including the port and database number)\nREDIS_URL=redis://localhost:6379/0\n\n# [Optional] The Redis namespace to use\nREDIS_NAMESPACE=some:namespace\n\n# [Optional] The polling interval in seconds (defaults to 60 seconds)\nINTERVAL=60\n\n# [Optional] A comma-separated list of tags\nTAGS=application:xxx,environment:yyy,hello:world\n\n# [Optional] The log level: either \"error\" or \"info\" (defaults to no logging)\nRUST_LOG=error\n```\n\nRun the binary:\n\n```bash\ndatadog-sidekiq\n```\n\nOr run it in the background:\n\n```bash\ndatadog-sidekiq \u0026\n```\n\nIf 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.\n\n## Docker\n\nThe app is also provided as a Docker image: https://hub.docker.com/r/lipanski/datadog-sidekiq\n\n## Build from source\n\nInstall [Rust](https://www.rust-lang.org) (latest stable version should be fine).\n\nClone the project, enter the project directory and run:\n\n```bash\ncargo build --release\n```\n\n## Alternative\n\nAnother way to track Sidekiq metrics in Datadog is by using the [Datadog Redis integration](https://docs.datadoghq.com/integrations/redis/). There are some drawbacks though and I haven't tried it out myself.\n\nFetching 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.\n\nIf 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* :)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flipanski%2Fdatadog-sidekiq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flipanski%2Fdatadog-sidekiq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flipanski%2Fdatadog-sidekiq/lists"}