Actions
Patch #613
closedAsynchronous email delivery
Description
As suggested at http://www.datanoise.com/articles/2006/7/14/asynchronous-email-delivery , the email delivery delay experienced by users can be almost eliminated creating a new Thread to handle the delivery.
This code at the public part of Mailer.rb model is the most simplistic way to achieve it :
@alias_method :old_deliver, :deliver! unless method_defined?(:old_deliver)
def deliver!()
Thread.start(mail) do |email|
old_deliver
end
end@
Related issues
Actions