No commit activity in last 3 years
No release in over 3 years
A Resque plugin for unique jobs
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

>= 1.8.0
 Project Readme

resque-unique-job

Depends on Resque 1.8

About

This is a gem that will prevent multiple of the same job being enqueued with resque.

It works by overriding the JobClass.enqueue method so you need to define a base class that defines self.enqueue before extending the plugin.

Examples

class BaseJob
  def self.enqueue(*args)
    Resque.enqueue(self, *args)
  end
end

class MyJob < BaseJob
  extend Resque::Plugins::UniqueJob

  def self.perform(*args)
    #do stuff
  end
end

Requirements