sidekiq_mailer | Send emails asynchronously using sidekiq | Email library
kandi X-RAY | sidekiq_mailer Summary
kandi X-RAY | sidekiq_mailer Summary
Send emails asynchronously using sidekiq
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of sidekiq_mailer
sidekiq_mailer Key Features
sidekiq_mailer Examples and Code Snippets
class MyMailer < ActionMailer::Base
include Sidekiq::Mailer
def welcome(to)
...
end
end
# Queues the mail to be sent asynchronously by sidekiq
MyMailer.welcome('your@email.com').deliver
sidekiq -q mailer
# Mail will skip sidekiq and
# config/initializers/sidekiq_mailer.rb
Sidekiq::Mailer.excluded_environments = [:test, :cucumber]
Community Discussions
Trending Discussions on sidekiq_mailer
QUESTION
I'm trying to migrate from rails 4.x to rails 5.x
gemfile.lock:
- rails (5.0.2)
- sidekiq_mailer (0.0.8)
- sidekiq (5.0.0)
- actionmailer (= 5.0.2)
For mailing stuff, when I try the following :
$>UserMailer.password_reset(account_to_reset).deliver_later
(which previously worked like a charm)
I got this error :
ArgumentError: wrong number of arguments (given 2, expected 0)
with (the full and only) following backtrace :
from /Users/nathangouy/.rvm/gems/ruby-2.4.1/gems/actionmailer-5.0.2/lib/action_mailer/base.rb:582:in 'initialize' from /Users/nathangouy/.rvm/gems/ruby-2.4.1/gems/sidekiq_mailer-0.0.8/lib/sidekiq_mailer/proxy.rb:11:in 'new' from /Users/nathangouy/.rvm/gems/ruby-2.4.1/gems/sidekiq_mailer-0.0.8/lib/sidekiq_mailer/proxy.rb:11:in 'actual_message' from /Users/nathangouy/.rvm/gems/ruby-2.4.1/gems/sidekiq_mailer-0.0.8/lib/sidekiq_mailer/proxy.rb:28:in 'method_missing'
I try a lot of things and wasn't able to find any similar issue on sidekiq or actionmailer
...ANSWER
Answered 2017-Jun-07 at 09:40Ok I found the problem, the thing is that sidekiq_mailer isn't maintained by the sidekiq author (I missed this crucial info), and then it's not usable for now with sidekiq/rails 5.x
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install sidekiq_mailer
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page