module ActiveJob::Locks::Options
Attributes
lock_type[R]
payload_lock[R]
queue_lock[R]
Public Instance Methods
lock_by(lock_type, options = {})
click to toggle source
# File lib/active_job/locks/options.rb, line 10 def lock_by(lock_type, options = {}) @lock_type = lock_type @queue_lock = @lock_type == :queue @payload_lock = @lock_type == :payload @options = options @redis = redis end
requeue_wait()
click to toggle source
# File lib/active_job/locks/options.rb, line 22 def requeue_wait @options[:requeue_wait] end
ttl()
click to toggle source
# File lib/active_job/locks/options.rb, line 18 def ttl @options[:ttl] || 1.minute end