[Catalyst] Sending 3000 emails.
Darren Duncan
darren at darrenduncan.net
Mon Nov 30 23:41:39 GMT 2015
On 2015-11-30 9:29 AM, Andrew wrote:
> ...given that my attempt to send 3000 emails with nothing but my own VPS server,
> and Cpan's Email::Stuffer, only sent around 1000, before the
> plack/fastcgi/catalyst app crashed.... could I have been running into a similar
> limitation? I'm now thinking of altering my code to split the attempts to send
> email into six batches of 500 emails, as a short term fix, until I've had time
> to research which transactional email partner to use, and how their APIs work,
> or integrate with Catalyst apps.
If you are trying to send the emails directly from the process serving your web
API, then this is absolutely the wrong approach, and you should give up
immediately on trying to do that. Your API process should just queue the
messages to be sent by a separate background process, and then return
immediately such as with a message "3000 messages queued to be sent soon, click
here to check queue progress" or such. Sending in-process may be reasonable for
a single email, eg email a copy of the form the user just submitted, but that's
it. -- Darren Duncan
More information about the Catalyst
mailing list