No commit activity in last 3 years
No release in over 3 years
Sidekiq middleware to log useful sidekiq stats to OpenTSDB.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 0
~> 11.1
~> 3.0

Runtime

~> 1.0
>= 2.6
 Project Readme

Sidekiq::Opentsdb

Build Status

Sidekiq middleware that sends useful Sidekiq statistics to OpenTSDB.

Installation

Add this line to your application's Gemfile:

gem 'sidekiq-opentsdb'

And then execute:

$ bundle

Usage

You need to add the middleware to your call stack. To do so, put the folllowing code in an initializer (ideally sidekiq.rb):

Sidekiq.configure_server do |config|
  config.server_middleware do |chain|
    middleware_options = {
      opentsdb_hostname: 'localhost',
      opentsdb_port: '4242',
      metric_prefix: 'nine',
      only: %w(retry_size dead_size)
    }

    chain.add Sidekiq::Opentsdb::ServerMiddleware, middleware_options
  end
end

Available Options

opentsdb_hostname: 'localhost'   # (required) Hostname of your opentsdb server.
opentsdb_port: '4242'            # (required) Port of your opentsdb server.

metric_prefix: 'nine'            # (optional) Prefix of the metric keys (default: '').
only:   %w(retry_size dead_size) # (optional) Only send the given metrics to OpenTSDB.
except: %w(retry_size dead_size) # (optional) Send all but the given metrics to OpenTSDB.

# Tags
app: 'MyApp'                     # (optional) Your app name (Rails app name if available)
environment: 'staging'           # (optional) Your app environment (default: ENV['RACK_ENV'])

About

This gem is currently maintained and funded by nine.

logo of the company 'nine'