Sha256: 2f504cca350a0d308b6e2c85321281df2ce75f50ac3e86d75cb55650f1cce98d
Contents?: true
Size: 582 Bytes
Versions: 10
Compression:
Stored size: 582 Bytes
Contents
module Resque class SettingNotFound < RuntimeError; end class ThrottledJob THROTTLE_DEFAULTS = { :can_run_every => 1800, :disabled => false, } def self.settings @settings ||= THROTTLE_DEFAULTS.dup end def self.throttle(args = {}) settings.merge!(args) end def self.identifier(*args) end def self.key(*args) [self.to_s, identifier(*args)].compact.join(":") end def self.can_run_every settings[:can_run_every] end def self.disabled settings[:disabled] end end end
Version data entries
10 entries across 10 versions & 2 rubygems