GithubHelp home page GithubHelp logo

sidekiq-failures's Introduction

Sidekiq::Failures Build Status

Keeps track of Sidekiq failed jobs and adds a tab to the Web UI to let you browse them. Makes use of Sidekiq's custom tabs and middleware chain.

It mimics the way Resque keeps track of failures.

WARNING: by default sidekiq-failures will keep up to 1000 failures. See Maximum Tracked Failures below.

Installation

Add this line to your application's Gemfile:

gem 'sidekiq-failures'

Usage

Simply having the gem in your Gemfile is enough to get you started. Your failed jobs will be visible via a Failures tab in the Web UI.

If you have not previously used the Web UI, it is a part of the Sidekiq gem. See Sidekiq's docs about Web UI here.

Configuring

Maximum Tracked Failures

Since each failed job/retry creates a new failure entry that will only be removed by you manually, your failures list might consume more resources than you have available.

To avoid this sidekiq-failures adopts a default of 1000 maximum tracked failures.

To change the maximum amount:

Sidekiq.configure_server do |config|
  config.failures_max_count = 5000
end

To disable the limit entirely:

Sidekiq.configure_server do |config|
  config.failures_max_count = false
end

Failures Tracking Mode

Sidekiq-failures offers three failures tracking options (per worker):

:all (default)

Tracks failures every time a background job fails. This mean a job with 25 retries enabled might generate up to 25 failure entries. If the worker has retry disabled only one failure will be tracked.

This is the default behavior but can be made explicit with:

class MyWorker
  include Sidekiq::Worker

  sidekiq_options :failures => true # or :all

  def perform; end
end

:exhausted

Only track failures if the job exhausts all its retries (or doesn't have retries enabled).

You can set this mode as follows:

class MyWorker
  include Sidekiq::Worker

  sidekiq_options :failures => :exhausted

  def perform; end
end

:off

You can also completely turn off failures tracking for a given worker as follows:

class MyWorker
  include Sidekiq::Worker

  sidekiq_options :failures => false # or :off

  def perform; end
end

Change the default mode

You can also change the default of all your workers at once by setting the following server config:

Sidekiq.configure_server do |config|
  config.failures_default_mode = :off
end

The valid modes are :all, :exhausted or :off.

Helper Methods

Failures Count

Gives back the number of failed jobs currently stored in Sidekiq Failures. Notice that it's different from Sidekiq built in failed stat. Also, notice that this might be influenced by failures_max_count.

Sidekiq::Failures.count

Reset and clear Failures

Gives a convenient way of resetting Sidekiq Failure stored failed jobs programmatically.

Sidekiq::Failures.clear_failures

To reset Sidekiq own failed stats.

Sidekiq::Failures.reset_failure_count

Dependencies

Depends on Sidekiq >= 4.0.0

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

License

Released under the MIT License. See the LICENSE file for further details.

sidekiq-failures's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

sidekiq-failures's Issues

Problems loading layout on failure page

Is anyone else having a problem with the failure page not loading within layout from sidekiq?

I just upgraded to sidekiq 2.15 and using sidekiq-failures 0.2.1 - I had to make a change in failures.slim line 6 to use erb template rendering instead of slim. The page now loads with the change, but basically without any of the styling etc loaded.

Failed jobs cleared but counter not reset causes nil method error

I'm running master on Sidekiq 3.0.

When the failed jobs are cleared but the counter isn't reset I get the following error when trying to load the failures page:

NoMethodError at /sidekiq/failures
undefined method `map' for nil:NilClass
file: web_helpers.rb location: display_args line: 111

Indicate number of pages in pagination

The pagination links for the failures page shows 2 page links and no indication of the number of pages. Would it be easy to have more page links shown and an indicator of how many pages are there?

Not install sinatra and slim on client

Hello, my app built on Rails so it is strange for me to have Sinatra in Gemfile.lock to handle Sidekiq failures.

Sinatra is great, btw.

Does it possible to somehow avoid this dependency on client? (I have separate monitoring app that loads Siqekiq::Web's Sinatra).

Create a new gem version

I deployed the gem on a server where in some failed jobs there was no traceback and it caused the panel to crash. I forked the repo in order to fix this but now I see that there is already a fix there but you had not triggered a build.

Failures Tab Not Available After Adding Gem

I may be starting sidekiq differently than sidekiq-failures is expecting so it can't hook into sidekiq. I added the gem and restarted my server and I don't see the failures tab. Is there anything I need to add to make sidekiq-failures to properly show up? Here is how I am starting the server:

#!/usr/bin/env ruby
require 'sidekiq/web'
app = Sidekiq::Web
app.set :environment, :production
app.set :bind, '0.0.0.0'
app.set :port, 9494
app.run!

Ruby Gems Version is not in Sync with Source Repo

The 2.2 release included a fix to catch all exceptions. However the gem version was not updated in that commit but instead it was updated in the 2.1 releases commit to 2.2.

So it looks like ruby gems thinks the 2.1 release is the 2.2 release and it did not rebuild the gem file with the new source. Can you rev the version to 2.3 and push a new gem.

Thanks for all the hard work on this.

Issues with sidekiq-pro

The gem does not seem to be working after upgrading the sidekiq-pro. The issue seems to be related to both pro and failures gem overloading the find_template in web_extensions to different locations. Has someone been able to get both working together? If so, would appreciate it if you shared.

Add option to disable retry for failures

Would it be possible to disable the "retry" button for the failures displayed by this gem? We twice had the problem that a developer thought that all entries in the failures tab need to be retried, while those jobs were already retried automatically and had passed already.

If you don't know exactly what this gem is for, it can be a little confusing.

Incompatible with sidekiq 3.0.0

I need to upgrade my sidekiq to 3.0.0, but your gem is broken with this version!

Please, update your amazing gem!

Thanks! :D

Do not see ruby trace in UI

Hello,

I am working on a project with sidekiq and I have an issue with workers. When a job fails, I do not see backtrace :

capture decran 2014-06-30 a 10 15 14

How can I do to display it?

Thx

Bump version

Hello! I was wondering when you are planning to bump the gem version next?

Deleting all failed items when on last page redirects back to same page

if I have six pages of failed jobs, and go to the last page(let's say six), and then select all and hit delete to get rid of that page's jobs..it performs that deletion, and then brings you back to the same page(sidekiq/failures?page=6) with the green "No failed jobs found" message. Have to click the "Failures" item of nav menu to see the rest of my remaining items on pages 1-5..

private method `retry_attempts_from' called

I periodically get this error on my production server:

NoMethodError: private method `retry_attempts_from' called for #<Sidekiq::Middleware::Server::RetryJobs:0x0000000a1ef078>

Backtrace:

sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:69:in `max_retries'
sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:61:in `last_try?'
sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:44:in `not_exhausted?'
sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:40:in `skip_failure?'
sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:14:in `rescue in call'
sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:9:in `call'
sidekiq-2.17.7/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
sidekiq-2.17.7/lib/sidekiq/middleware/server/active_record.rb:6:in `call'
sidekiq-2.17.7/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
sidekiq-2.17.7/lib/sidekiq/middleware/server/retry_jobs.rb:62:in `call'
sidekiq-2.17.7/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
sidekiq-2.17.7/lib/sidekiq/middleware/server/logging.rb:11:in `block in call'
sidekiq-2.17.7/lib/sidekiq/logging.rb:22:in `with_context'
sidekiq-2.17.7/lib/sidekiq/middleware/server/logging.rb:7:in `call'
sidekiq-2.17.7/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
sidekiq-2.17.7/lib/sidekiq/middleware/chain.rb:127:in `call'
sidekiq-2.17.7/lib/sidekiq/middleware/chain.rb:127:in `invoke'
sidekiq-2.17.7/lib/sidekiq/processor.rb:48:in `block (2 levels) in process'
sidekiq-2.17.7/lib/sidekiq/processor.rb:108:in `stats'
sidekiq-2.17.7/lib/sidekiq/processor.rb:47:in `block in process'
sidekiq-2.17.7/lib/sidekiq/processor.rb:86:in `do_defer'
sidekiq-2.17.7/lib/sidekiq/processor.rb:37:in `process'
celluloid-0.15.2/lib/celluloid/calls.rb:25:in `public_send'
celluloid-0.15.2/lib/celluloid/calls.rb:25:in `dispatch'
celluloid-0.15.2/lib/celluloid/calls.rb:122:in `dispatch'
celluloid-0.15.2/lib/celluloid/actor.rb:322:in `block in handle_message'
celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

GUI: failures sorted by time - newest first

Wouldn't it be better to display failures sorted by 'newest first'? Or maybe making it an option in config? Or make a "Failed At" a link to sort?

What do you think is best? I can make a PR then if you're interested

conflicts with sidetiq and sidekiq-unique

Hi, I'm having some weird problems with sidekiq-failures, it appears to conflict with most sidekiq extensions I use:

My setup:

gem 'sidekiq'
gem 'sidekiq-failures', github: 'mhfs/sidekiq-failures'
gem 'sidekiq-unique-jobs'
gem 'sidetiq'
gem 'sinatra', require: false
gem 'slim'

Gemfile.lock:

https://gist.github.com/ngw/10109084

With sidetiq enabled:

https://gist.github.com/ngw/10109137

With sidetiq disabled:

https://gist.github.com/ngw/10109220

Any clues?

Failed At is way out

When a job fails, the time that I get is way out:

screen shot 2013-05-28 at 12 03 09 pm

This only failed a few minutes ago and is being reported as 15 hours ago.

My system timezone is set to Australia/Sydney, so that might be causing issues?

NoMethodError: private method `retry_attempts_from'

When I try to process a queue Sidekiq::Processor crashes because of this error.

Full stacktrace:

2013-12-05T07:19:19Z 5480 TID-esg0w ERROR: Sidekiq::Processor crashed!
NoMethodError: private method `retry_attempts_from' called for #<Sidekiq::Middleware::Server::RetryJobs:0x00000004269d60>
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:69:in `max_retries'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:61:in `last_try?'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:44:in `not_exhausted?'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:40:in `skip_failure?'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:14:in `rescue in call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-failures-0.2.2/lib/sidekiq/failures/middleware.rb:9:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/server/active_record.rb:6:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/server/retry_jobs.rb:62:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/server/logging.rb:11:in `block in call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/logging.rb:22:in `with_context'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/server/logging.rb:7:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/chain.rb:124:in `block in invoke'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/chain.rb:127:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/middleware/chain.rb:127:in `invoke'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/processor.rb:48:in `block (2 levels) in process'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/processor.rb:105:in `stats'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/processor.rb:47:in `block in process'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `public_send'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `dispatch'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:67:in `dispatch'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/future.rb:14:in `block in new'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/thread_handle.rb:13:in `block in initialize'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/internal_pool.rb:100:in `call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/internal_pool.rb:100:in `block in create'
    (celluloid):0:in `remote procedure call'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/future.rb:104:in `value'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/future.rb:68:in `value'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid.rb:456:in `defer'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/processor.rb:84:in `do_defer'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/sidekiq-2.17.0/lib/sidekiq/processor.rb:37:in `process'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `public_send'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:25:in `dispatch'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/calls.rb:122:in `dispatch'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/actor.rb:322:in `block in handle_message'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
    /usr/local/rvm/gems/ruby-1.9.3-p484/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

The versions I am using is:

  * sidekiq (2.17.0)
  * sidekiq-failures (0.2.2)
  * sidekiq-status (0.3.2)

Please help...

sidekiq-failures - request for feedback

Guys, I'm writing because in the Sidekiq issues you somehow got involved in middleware or failed jobs discussions.

I've released a pre version of the sidekiq-failures gem which adds the ability to track failed jobs and a tab to the web UI that allows browsing them.

There is still a lot to do (check the todo section in the readme) but I'd like to involve interested people ASAP.

Please feel free to write back and/or create issues.

Thanks!

/cc @leomao10 @greyblake @baburdick @fbjork @eignerchris @mhenrixon @masterkain @ROYBOTNIK @jc00ke @dgtm

Looking for co-maintainer

Hi guys, I'm looking for someone to join me as co-maintainer of sidekiq-failures.

I haven't been having the amount of time I'd like to take proper care of this gem and having someone to help me would make things quicker and better.

Desirable characteristics:

  • active use of sidekiq-failures in live production apps
  • history of contributions for OSS

Please get in touch.

Failures UI crashing with error - TypeError - can't convert String into an exact number

In my rails app, when I visit sidekiq web UI and click on Failure link, the app crashed with following error:

TypeError - can't convert String into an exact number:
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/core_ext/time/calculations.rb:60:in `at'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/core_ext/time/calculations.rb:60:in `at_with_coercion'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:56:in `block (2 levels) in singleton class'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:42:in `each'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:42:in `block in singleton class'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:7:in `instance_eval'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:7:in `singleton class'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:5:in `__tilt_79531910'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/tilt-1.4.1/lib/tilt/template.rb:170:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/tilt-1.4.1/lib/tilt/template.rb:170:in `evaluate'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/tilt-1.4.1/lib/tilt/template.rb:103:in `render'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:711:in `render'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:13:in `block in registered'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:1293:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:1293:in `block in compile!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:860:in `[]'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:860:in `block (3 levels) in route!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:876:in `route_eval'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/agent/instrumentation/sinatra.rb:133:in `route_eval_with_newrelic'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:860:in `block (2 levels) in route!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:897:in `block in process_route'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:895:in `catch'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:895:in `process_route'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/agent/instrumentation/sinatra.rb:116:in `process_route_with_newrelic'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:859:in `block in route!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:858:in `each'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:858:in `route!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:963:in `block in dispatch!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:946:in `block in invoke'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:946:in `catch'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:946:in `invoke'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:960:in `dispatch!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/agent/instrumentation/sinatra.rb:151:in `dispatch_and_notice_errors_with_newrelic'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/agent/instrumentation/sinatra.rb:146:in `block in dispatch_with_newrelic'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/agent/instrumentation/controller_instrumentation.rb:318:in `perform_action_with_newrelic_trace'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/agent/instrumentation/sinatra.rb:143:in `dispatch_with_newrelic'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:794:in `block in call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:946:in `block in invoke'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:946:in `catch'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:946:in `invoke'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:794:in `call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:780:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/error_collector.rb:43:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/browser_monitoring.rb:16:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/agent_hooks.rb:22:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-protection-1.5.0/lib/rack/protection/xss_header.rb:18:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-protection-1.5.0/lib/rack/protection/path_traversal.rb:16:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-protection-1.5.0/lib/rack/protection/json_csrf.rb:18:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-protection-1.5.0/lib/rack/protection/base.rb:49:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-protection-1.5.0/lib/rack/protection/base.rb:49:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-protection-1.5.0/lib/rack/protection/frame_options.rb:31:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/nulllogger.rb:9:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/head.rb:9:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/showexceptions.rb:21:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:124:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:1417:in `block in call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:1499:in `synchronize'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sinatra-1.3.6/lib/sinatra/base.rb:1417:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/routing/mapper.rb:43:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/journey-1.0.4/lib/journey/router.rb:68:in `block in call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/journey-1.0.4/lib/journey/router.rb:56:in `each'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/journey-1.0.4/lib/journey/router.rb:56:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/routing/route_set.rb:608:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:177:in `call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:157:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:177:in `call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:157:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:177:in `call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:157:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:177:in `call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:157:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:177:in `call!'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/strategy.rb:157:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/bundler/gems/omniauth-e34cf672cd02/lib/omniauth/builder.rb:48:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/bullet-4.3.0/lib/bullet/rack.rb:8:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/error_collector.rb:43:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/agent_hooks.rb:22:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/browser_monitoring.rb:16:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/newrelic_rpm-3.6.6.147/lib/new_relic/rack/developer_mode.rb:28:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/sass-3.2.3/lib/sass/plugin/rack.rb:54:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-pjax-0.6.0/lib/rack/pjax.rb:12:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/warden-1.1.1/lib/warden/manager.rb:35:in `block in call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/warden-1.1.1/lib/warden/manager.rb:34:in `catch'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/warden-1.1.1/lib/warden/manager.rb:34:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/etag.rb:23:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/conditionalget.rb:25:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/head.rb:14:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/params_parser.rb:21:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/flash.rb:242:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/session/abstract/id.rb:210:in `context'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/session/abstract/id.rb:205:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/cookies.rb:341:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activerecord-3.2.17/lib/active_record/query_cache.rb:64:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activerecord-3.2.17/lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/callbacks.rb:28:in `block in call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/callbacks.rb:405:in `_run__10242884__call__891201541__callbacks'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/callbacks.rb:405:in `__run_callback'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/callbacks.rb:81:in `run_callbacks'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/reloader.rb:65:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/airbrake-3.1.12/lib/airbrake/rails/middleware.rb:13:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/rack/logger.rb:32:in `call_app'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/rack/logger.rb:16:in `block in call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/tagged_logging.rb:22:in `tagged'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/rack/logger.rb:16:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/quiet_assets-1.0.2/lib/quiet_assets.rb:18:in `call_with_quiet_assets'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/request_id.rb:22:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/methodoverride.rb:21:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/runtime.rb:17:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/activesupport-3.2.17/lib/active_support/cache/strategy/local_cache.rb:72:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/lock.rb:15:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/actionpack-3.2.17/lib/action_dispatch/middleware/static.rb:63:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/font_assets-0.1.11/lib/font_assets/middleware.rb:29:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/airbrake-3.1.12/lib/airbrake/user_informer.rb:16:in `_call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/airbrake-3.1.12/lib/airbrake/user_informer.rb:12:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/engine.rb:484:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/application.rb:231:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/railtie/configurable.rb:30:in `method_missing'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/deflater.rb:13:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/content_length.rb:14:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/rack/debugger.rb:20:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/rack/log_tailer.rb:17:in `call'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/connection.rb:81:in `block in pre_process'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/connection.rb:79:in `catch'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/connection.rb:79:in `pre_process'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/connection.rb:54:in `process'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/connection.rb:39:in `receive_data'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/eventmachine-1.0.3/lib/eventmachine.rb:187:in `run_machine'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/eventmachine-1.0.3/lib/eventmachine.rb:187:in `run'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/backends/base.rb:63:in `start'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/thin-1.5.1/lib/thin/server.rb:159:in `start'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/handler/thin.rb:13:in `run'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/rack-1.4.5/lib/rack/server.rb:268:in `start'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/commands/server.rb:70:in `start'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/commands.rb:55:in `block in <top (required)>'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/commands.rb:50:in `tap'
  /home/kiprosh/.rvm/gems/ruby-2.0.0-p353@realvolve/gems/railties-3.2.17/lib/rails/commands.rb:50:in `<top (required)>'
  script/rails:6:in `require'
  script/rails:6:in `<main>'

My app is running on Rails v3.2.17 with ruby v2.0.0-p353.

Here is the part of Gemfile.lock involving sidekiq-pro and related gems.

    sidekiq (3.0.0)
      celluloid (>= 0.15.2)
      connection_pool (>= 2.0.0)
      json
      redis (>= 3.0.6)
      redis-namespace (>= 1.3.1)
    sidekiq-failures (0.4.1)
      sidekiq (>= 2.16.0)
    sidekiq-pro (1.7.0)
      sidekiq (>= 3)
    sidekiq-unique-jobs (3.0.0)
      mock_redis
      sidekiq (>= 2.6)

Am I missing something here?

Note: I recently updated sidekiq-failure from 0.1.0 to 0.4.1.

uninitialized constant Sidekiq::Shutdown

hi there,
I am using the Sidekiq::Failure to view failure for all sidekiq workers. But due to the following issue we cannot see the failures.

It appears that Sidekiq::Shutdown is not defined anywhere inside sidekiq gem or sidekiq-failure gem. If I define Sidekiq::Shutdown exception then this issue goes away and I can see all the failures.

sidekiq version 2.5.2
sidekiq-failure version 0.2.1

here is the backtrace

2013-07-23T23:35:07Z 2035 TID-ov41ybqqs Graph::MyWorker MSG-cc8d1da0f3d50e5688c53739 INFO: start
2013-07-23T23:35:07Z 2035 TID-ov41ybqqs Graph::MyWorker MSG-cc8d1da0f3d50e5688c53739 INFO: About to process a job with args [#Graph::MyWorker:0x007f97b92cb228, {"retry"=>false, "queue"=>"graph", "failures"=>"all", "class"=>"Graph::MyWorker", "args"=>[], "jid"=>"cc8d1da0f3d50e5688c53739"}, "graph"]
2013-07-23T23:35:07Z 2035 TID-ov41ybqqs Graph::MyWorker MSG-cc8d1da0f3d50e5688c53739 INFO: fail: 0.001 sec
2013-07-23T23:35:07Z 2035 TID-ov41ybqqs WARN: {"retry"=>false, "queue"=>"graph", "failures"=>"all", "class"=>"Graph::MyWorker", "args"=>[], "jid"=>"cc8d1da0f3d50e5688c53739"}
2013-07-23T23:35:07Z 2035 TID-ov41ybqqs WARN: uninitialized constant Sidekiq::Shutdown
2013-07-23T23:35:07Z 2035 TID-ov41ybqqs WARN: /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-failures-0.2.1/lib/sidekiq/failures/middleware.rb:12:in rescue in call' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-failures-0.2.1/lib/sidekiq/failures/middleware.rb:10:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:81:in block in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-unique-jobs-2.3.2/lib/sidekiq-unique-jobs/middleware/server/unique_jobs.rb:9:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:81:in block in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/server/timeout.rb:14:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:81:in block in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/server/active_record.rb:6:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:81:in block in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/server/retry_jobs.rb:49:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:81:in block in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/server/logging.rb:11:inblock in call'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/logging.rb:22:in with_context' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/server/logging.rb:7:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:81:in block in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:84:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/middleware/chain.rb:84:in invoke' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/processor.rb:41:inblock (2 levels) in process'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/processor.rb:76:in stats' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/sidekiq-2.5.2/lib/sidekiq/processor.rb:40:inblock in process'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/celluloid-0.12.3/lib/celluloid/calls.rb:57:in call' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/celluloid-0.12.3/lib/celluloid/calls.rb:57:indispatch'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/celluloid-0.12.3/lib/celluloid/future.rb:18:in block in initialize' /Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/celluloid-0.12.3/lib/celluloid/internal_pool.rb:48:incall'
/Users/ranbirsingh/Documents/ruby-workspace/playup-news/gems/ruby/1.9.1/gems/celluloid-0.12.3/lib/celluloid/internal_pool.rb:48:in `block in create'

thanks.

Issues with Sidekiq 3.0.0 in Production

Hi,

I just deployed the updated version of Sidekiq and Sidekiq-failures, but something is still not playing well:


NoMethodError - undefined method `map' for nil:NilClass:
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-3.0.0/lib/sidekiq/web_helpers.rb:111:in `display_args'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:51:in `block (2 levels) in singleton class'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:42:in `each'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:42:in `block in singleton class'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:7:in `instance_eval'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:7:in `singleton class'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:5:in `__tilt_70346096426640'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/tilt-1.4.1/lib/tilt/template.rb:170:in `call'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/tilt-1.4.1/lib/tilt/template.rb:170:in `evaluate'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/tilt-1.4.1/lib/tilt/template.rb:103:in `render'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:805:in `render'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:13:in `block in registered'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1593:in `call'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1593:in `block in compile!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:957:in `[]'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:957:in `block (3 levels) in route!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:976:in `route_eval'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/newrelic_rpm-3.7.0.177/lib/new_relic/agent/instrumentation/sinatra.rb:133:in `route_eval_with_newrelic'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:957:in `block (2 levels) in route!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:997:in `block in process_route'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:995:in `catch'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:995:in `process_route'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/newrelic_rpm-3.7.0.177/lib/new_relic/agent/instrumentation/sinatra.rb:116:in `process_route_with_newrelic'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:955:in `block in route!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:954:in `each'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:954:in `route!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1067:in `block in dispatch!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1049:in `block in invoke'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1049:in `catch'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1049:in `invoke'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/sinatra-1.4.4/lib/sinatra/base.rb:1064:in `dispatch!'
    /home/its/apps/ferrovial/shared/bundle/ruby/2.0.0/gems/newrelic_rpm-3.7.0.177/lib/new_relic/agent/instrumentation/sinatra.rb:151:in `dispatch_and_notice_errors_with_newrelic'

Any insight on this?

Thanks in advance

Show newest failures first

The old behavior seems to have changed in this commit: 8ae69a3

Can we do lpush instead of rpush to get most recent failures listed first again?

Reconsider :exhausted option

Sidekiq 3.0.0 introduced Dead Job Queue, which basically duplicates sidekiq-failures behavior when :exhausted mode is used.

I think that it makes no sense to support this option from now on. @mhfs, your thoughts?

Sidekiq 2 failure timestamps were Strings, not Floats.

Hi,

unfortunately I lost the backtrace, but the failure timestamps stored in Redis from Sidekiq 2 were Strings like '2014-05-22T11:06:08Z', not Floats, so after upgrading to Sidekiq 3 and your master branch, the conversion at this line fails, leading to a HTTP 500.

We fixed it temporarily by replacing it like this:

<td><%= relative_time(entry['failed_at'].is_a?(Float) ? Time.at(entry['failed_at']) : Time.parse(entry['failed_at'])) %></td>

Should I bother sending a pull request or would you simply ignore this (i.e. requiring a full discard of old failures?)?

When failures is set to exhausted, failed count still increments at every failure

I always set failures to exhausted (I don't want the failure to be recorded until it's been tried a few times because a lot of what we are doing is related to external services).

This seems to work properly, however I've noticed that at every failure (even before the job is exhausted), the failed count still increments. I don't know if this is a bug or by design, but I'd like to be able to see the failed count represent the exhausted count (or rather, the number of failures that are seen on the failures page).

Failures tab not working with 3.0.2 ?

Hi guys,

I've just updated Sidekiq / Pro and apparently the failures tab doesn't seem to work anymore.

My gem versions:

  • sidekiq (3.0.2)
  • sidekiq-failures (0.4.1)
  • sidekiq-pro (1.7.1)

This is what I'm getting:

TypeError - can't convert String into an exact number:
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/core_ext/time/calculations.rb:60:in at' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/core_ext/time/calculations.rb:60:inat_with_coercion'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:56:in block (2 levels) in singleton class' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:42:ineach'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:42:in block in singleton class' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:7:ininstance_eval'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:7:in singleton class' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:5:in__tilt_70163478156240'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/tilt-1.4.1/lib/tilt/template.rb:170:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/tilt-1.4.1/lib/tilt/template.rb:170:inevaluate'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/tilt-1.4.1/lib/tilt/template.rb:103:in render' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:814:inrender'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/web_extension.rb:13:in block in registered' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1603:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1603:in block in compile!' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:966:in[]'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:966:in block (3 levels) in route!' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:985:inroute_eval'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/agent/instrumentation/sinatra.rb:136:in route_eval_with_newrelic' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:966:inblock (2 levels) in route!'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1006:in block in process_route' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1004:incatch'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1004:in process_route' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/agent/instrumentation/sinatra.rb:116:inprocess_route_with_newrelic'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:964:in block in route!' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:963:ineach'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:963:in route!' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1076:inblock in dispatch!'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in block in invoke' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:incatch'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in invoke' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1073:indispatch!'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/agent/instrumentation/sinatra.rb:156:in dispatch_and_notice_errors_with_newrelic' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/agent/instrumentation/sinatra.rb:151:inblock in dispatch_with_newrelic'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/agent/instrumentation/controller_instrumentation.rb:357:in perform_action_with_newrelic_trace' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/agent/instrumentation/sinatra.rb:148:indispatch_with_newrelic'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:898:in block in call!' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:inblock in invoke'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in catch' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:ininvoke'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:898:in call!' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:886:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/rack/error_collector.rb:55:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/rack/browser_monitoring.rb:27:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/rack/agent_hooks.rb:32:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-protection-1.5.3/lib/rack/protection/xss_header.rb:18:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-protection-1.5.3/lib/rack/protection/path_traversal.rb:16:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-protection-1.5.3/lib/rack/protection/json_csrf.rb:18:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-protection-1.5.3/lib/rack/protection/frame_options.rb:31:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/nulllogger.rb:9:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/head.rb:9:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:180:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:2014:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1478:inblock in call'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1788:in synchronize' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1478:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/journey-1.0.4/lib/journey/router.rb:68:in block in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/journey-1.0.4/lib/journey/router.rb:56:ineach'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/journey-1.0.4/lib/journey/router.rb:56:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/routing/route_set.rb:608:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/apipie-rails-0.2.0/lib/apipie/static_dispatcher.rb:65:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/barista-1.3.0/lib/barista/server.rb:33:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/apipie-rails-0.2.0/lib/apipie/extractor/recorder.rb:97:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/rack/agent_hooks.rb:32:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/newrelic_rpm-3.8.1.221/lib/new_relic/rack/browser_monitoring.rb:27:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/request_store-1.0.5/lib/request_store/middleware.rb:9:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/warden-1.2.3/lib/warden/manager.rb:35:in block in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/warden-1.2.3/lib/warden/manager.rb:34:incatch'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/warden-1.2.3/lib/warden/manager.rb:34:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/best_standards_support.rb:17:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/etag.rb:23:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/conditionalget.rb:25:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/head.rb:14:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/params_parser.rb:21:incall'
/home/web/app/rails/current/app/middleware/params_parser_rescue.rb:4:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/flash.rb:242:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/session/abstract/id.rb:210:in context' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/session/abstract/id.rb:205:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/cookies.rb:341:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activerecord-3.2.18/lib/active_record/query_cache.rb:64:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activerecord-3.2.18/lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/callbacks.rb:28:inblock in call'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/callbacks.rb:405:in _run__1651555402998987625__call__2979240344088927473__callbacks' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/callbacks.rb:405:in__run_callback'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/callbacks.rb:385:in _run_call_callbacks' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/callbacks.rb:81:inrun_callbacks'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/callbacks.rb:27:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/remote_ip.rb:31:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/airbrake-3.1.16/lib/airbrake/rails/middleware.rb:13:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/debug_exceptions.rb:16:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/show_exceptions.rb:56:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/rack/logger.rb:32:incall_app'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/rack/logger.rb:16:in block in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/activesupport-3.2.18/lib/active_support/tagged_logging.rb:22:intagged'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/rack/logger.rb:16:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/quiet_assets-1.0.2/lib/quiet_assets.rb:18:incall_with_quiet_assets'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/actionpack-3.2.18/lib/action_dispatch/middleware/request_id.rb:22:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/methodoverride.rb:21:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/runtime.rb:17:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-1.4.5/lib/rack/lock.rb:15:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-cache-1.2/lib/rack/cache/context.rb:136:in forward' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-cache-1.2/lib/rack/cache/context.rb:245:infetch'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-cache-1.2/lib/rack/cache/context.rb:185:in lookup' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-cache-1.2/lib/rack/cache/context.rb:66:incall!'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/rack-cache-1.2/lib/rack/cache/context.rb:51:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/airbrake-3.1.16/lib/airbrake/user_informer.rb:16:in_call'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/airbrake-3.1.16/lib/airbrake/user_informer.rb:12:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/engine.rb:484:incall'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/application.rb:231:in call' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/railtie/configurable.rb:30:inmethod_missing'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:576:in process_client' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:670:inworker_loop'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:525:in spawn_missing_workers' /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:140:instart'
/home/web/app/rails/shared/bundle/ruby/2.1.0/gems/unicorn-4.8.3/bin/unicorn:126:in <top (required)>' /home/web/app/rails/shared/bundle/ruby/2.1.0/bin/unicorn:23:inload'
/home/web/app/rails/shared/bundle/ruby/2.1.0/bin/unicorn:23:in `

'

This is only happening on an environment that I already had some failures and upgraded to Sidekiq Pro 1.7, locally if I make a worker fail on purpose it shows up nicely. If I try to clear the set manually, this is what happens:

Loading staging environment (Rails 3.2.18)
irb(main):001:0> Sidekiq::Failures::FailureSet.new.clear
Redis::CommandError: ERR Operation against a key holding the wrong kind of value
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/redis-3.0.7/lib/redis/client.rb:97:in call' from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/redis-3.0.7/lib/redis.rb:1371:inblock in zcard'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/redis-3.0.7/lib/redis.rb:37:in block in synchronize' from /home/web/.rbenv/versions/2.1.2/lib/ruby/2.1.0/monitor.rb:211:inmon_synchronize'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/redis-3.0.7/lib/redis.rb:37:in synchronize' from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/redis-3.0.7/lib/redis.rb:1370:inzcard'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/redis-namespace-1.4.1/lib/redis/namespace.rb:352:in method_missing' from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-3.0.2/lib/sidekiq/api.rb:301:inblock in size'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/connection_pool-2.0.0/lib/connection_pool.rb:58:in with' from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-3.0.2/lib/sidekiq.rb:69:inredis'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-3.0.2/lib/sidekiq/api.rb:301:in size' from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-3.0.2/lib/sidekiq/api.rb:297:ininitialize'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/sidekiq-failures-0.4.1/lib/sidekiq/failures/failure_set.rb:12:in initialize' from (irb):1:innew'
from (irb):1
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/commands/console.rb:47:in start' from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/commands/console.rb:8:instart'
from /home/web/app/rails/shared/bundle/ruby/2.1.0/gems/railties-3.2.18/lib/rails/commands.rb:41:in <top (required)>' from script/rails:6:inrequire'

Is there a way to clear the failures queue manually with redis-cli to get rid of this problem? I'm a bit of a Redis noob.

Thanks in advance!

Failure improvements

When I delete all jobs via button, I realized that jobs were dropped,
but I have " a Failed count" > 0 and no way to reset this counter.

I opened the console, and try to got this number via sidekiq-failures api

Sidekiq::RedisConnection.create.with{|a| a.zcard(:failed)}
2014-05-05T21:48:50Z 10350 TID-znnu9k INFO: Sidekiq client with redis options {}
=> 0

Then, I opened the sidekiq api, I got another way to get this number

 Sidekiq::Stats.new.failed

This is the right counter.

So I had replaced counter and move button from @failures.size condition, to reset counter anyway, there are Failed jobs or not.

Show failures by worker name

Hello!
Find some failed jobs in big list - hard way))
Can i try to make sort functionality for failed jobs?
My idea fits into the overall concept of gem?
Sorry for bad english - I can try to explain my ideas, if necessary

Un-styled page

The page is empty but for the contents of an h3 and a div if used with sidekiq 2.14.0 (repo head, currently unreleased).

new version

Hey, when new version is going to be released?

Installation problem...

I have added the gem in my Gemfile, restart unicorn but the tab is not there.

I have added require sidekiq/failures in my config.ru

require 'sidekiq'

require 'sidekiq/web'
require 'sidekiq/failures'
run Sidekiq::Web

bundle exec unicorn

Open the sidekiq web front, Failures tab is there. I have some Failed jobs but I get No failed jobs found

What am I doing wrong?

Thanx
ps. I am using sidekiq 2.5.2

Release 0.4.2

Have the problem, which was fixed in 3bd17fb . Could you release 0.4.2 including this fix?

The new CSRF protection breaks retry/delete functionality

https://github.com/mperham/sidekiq/blob/master/Changes.md#342

There's a new csrf_tag being used throughout the sidekiq web ui now. You can see an example of it in use in the schedule page.

The lack of this tag is causing the site to respond with Forbidden instead of retrying/deleting the failed jobs (which I incorrectly reported over in #1289).

I haven't had the chance to test whether there's further setup needed elsewhere in this gem, or if simply including <%= csrf_tag %> within the form will resolve the issue. I hope to update this issue later, after I have a chance to test that out.

ActiveJob integration

I moved from plain Sidekiq to ActiveJob backed by Sidekiq, and now my failures tab displays ActiveJob::QueueAdapters::SidekiqAdapter::JobWrapper as Worker and the actual class is burrowed inside Arguments

{"job_class"=>"<ACTUAL_CLASS_NAME>", 
"job_id"=>"be4e36fa-4f71-46f9-abd7-d169b89fe0fc",
"queue_name"=>"default", "arguments"=>[]}

Maybe it is useful to display the actual class name at least just on the list view?

display_args does not trap nil

Parameter args is nil.

NoMethodError: undefined method `map' for nil:NilClass

gems/sidekiq-2.17.7/lib/sidekiq/web_helpers.rb:120:in `display_args`
gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:51:in `block (2 levels) in singleton class`
gems/sidekiq-failures-0.4.0/lib/sidekiq/failures/web_extension.rb:42:in `each`

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.