So I have a list of 90,000 users that receive my newsletter. Right now I have it configured to send out via cron 2,000 emails per run. Any higher and it causes the cron to timeout. So that means cron would need to run 45 times in order to send a newsletter to my entire list. Is there any way that I could batch api or something like that to keep pushing the emails to the mail spool?

Thanks!
-Chris

Comments

berdir’s picture

Status: Active » Fixed

You can use for example use elysia_cron to call simplenews_cron every two minutes (without doing so for other cron hooks) or so so that it's processed quicker.

You could also write your own scripts which call simplenews_mail_spool(), you can even do this in parallel as Simplenews prevents duplicates as it lockes the mail spool entries before trying to send them.

Simplenews 7.x-1.x now has batch API integration for sending immediately and drush integration which allows to create send scripts more easily but these changes will most likely not be backported as they depend on a number of refactorings and improvements that have happened in the 7.x-1.x version.

clkeenan’s picture

Elysia cron is definitely the answer I was looking for! Thanks :)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.