Module: Sidekiq::Extensions::ActionMailer

Defined in:
lib/sidekiq/extensions/action_mailer.rb

Instance Method Summary collapse

Instance Method Details

#sidekiq_delay(options = {}) ⇒ Object Also known as: delay


42
43
44
# File 'lib/sidekiq/extensions/action_mailer.rb', line 42

def sidekiq_delay(options={})
  Proxy.new(DelayedMailer, self, options)
end

#sidekiq_delay_for(interval, options = {}) ⇒ Object Also known as: delay_for


45
46
47
# File 'lib/sidekiq/extensions/action_mailer.rb', line 45

def sidekiq_delay_for(interval, options={})
  Proxy.new(DelayedMailer, self, options.merge('at' => Time.now.to_f + interval.to_f))
end

#sidekiq_delay_until(timestamp, options = {}) ⇒ Object Also known as: delay_until


48
49
50
# File 'lib/sidekiq/extensions/action_mailer.rb', line 48

def sidekiq_delay_until(timestamp, options={})
  Proxy.new(DelayedMailer, self, options.merge('at' => timestamp.to_f))
end