Project

General

Profile

Send mails from Redmine asynchronously

Added by demas demas about 10 years ago

As I know Redmine sends mail notification in the main transaction. For example, when the user post new note it will not be stored in the database until mail notification will be sended. In the result the user have to wait it and Nginx are keeping open connection (if mail server slow).

I am just wondering if there was any attempts to send mails from Redmine asynchronously? It may be some sort of Queue, or redmine plugin ? Or may be there is any plans to change such Redmine behaviuor ?


Replies (4)

RE: Send mails from Redmine asynchronously - Added by Marco Gutsche about 10 years ago

It is possible to configure redmine to asynchrously send the e-mails:

link to wiki

RE: Send mails from Redmine asynchronously - Added by demas demas about 10 years ago

Thanks. I didn't know about it.
I have tried it, but it don't work for me. If I change settings to:

delivery_method: :async_smtp
async_smtp_settings:

the mails stop sending.

I have 'enable_starttls_auto: false' in my configuration.yml file.
Is there something what I need to check ?

RE: Send mails from Redmine asynchronously - Added by Marco Gutsche about 10 years ago

I'm using enable_starttls_auto: true but I hadn't any problems chaning to asynchronous-mode, sorry.

RE: Send mails from Redmine asynchronously - Added by demas demas about 10 years ago

I have launched Redmine two times (with async and without async options) and compared console output. Around 100 lines after:

  Rendered mailer/_issue.html.erb (1.7ms)
  Rendered mailer/issue_edit.html.erb within layouts/mailer (4.1ms)

The output the same, except the time of execution. But Redmine don't send the mail with async option.
Is there any additional logs where I can find details ?

Thanks.

    (1-4/4)