Resque Noti Failure

Sends resque failure to noti (notiapp.com), a tool allowing you to receive notifications directly on you desktop.

Installation

You can let bundler install Resque Noti Failure by adding this line to your application’s Gemfile:

gem 'resque-noti-failure'

And then execute:

bundle install

Or install it yourself with:

gem install resque-noti-failure

Configuration

Before using this gem, you’ll need registering your application to noti (notiapp.com/apps) and adding your API Key :

Noti.app = 'your-api-key'

You can configure the way Resque Noti Failure like this :

Resque::Plugins::NotiFailure::Failure.configure do |config|
  config.failure_url = 'http://test.host/resque/failure'
  config.failure_name = 'resque test'
  config.failure_message = lambda{|payload| payload['class'].to_s}
end

Finally, you have to add a new failure backend to resque (more info about this on github.com/resque/resque/wiki/Failure-Backends) :

require 'resque/failure/multiple'
require 'resque/failure/redis'
require 'resque/plugins/noti_failure/failure'

Resque::Failure::Multiple.classes = [Resque::Failure::Redis, Resque::Plugins::NotiFailure::Failure]
Resque::Failure.backend = Resque::Failure::Multiple

Subscribe to notifications

Once configured, you can subscribe to failure notifications through resque-web interface.

Build status

<img src=“https://travis-ci.org/jpl/resque-noti-failure.png?branch=master” alt=“Build Status” /> <img src=“https://codeclimate.com/github/jpl/resque-noti-failure.png” /> <img src=“https://gemnasium.com/jpl/resque-noti-failure.png” alt=“Dependency Status” />

Contributing to resque-noti

  • Check out the latest master to make sure the feature hasn’t been implemented or the bug hasn’t been fixed yet.

  • Check out the issue tracker to make sure someone already hasn’t requested it and/or contributed it.

  • Fork the project.

  • Start a feature/bugfix branch.

  • Commit and push until you are happy with your contribution.

  • Make sure to add tests for it. This is important so I don’t break it in a future version unintentionally.

  • Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.

Copyright © 2013 Jean-Philippe Lecaille. See LICENSE.txt for further details.