cLive ;-) has asked for the wisdom of the Perl Monks concerning the following question:
Hi all,
In my evergoing quest to make my CGI scripts cross platform, I've moved the e-mail sending subs over to Net::SMTP (I used to use just sendmail, but the NT people weren't very happy :).
In testing though, I notice that there is a significant difference in performance when sending using Net::SMTP over piping to Sendmail. I assume this is because piping to Sendmail just puts the message in the mail queue, whereas Net::SMTP actually physically sends the mail.
So, my question is, to avoid the overhead:
- should I fork the sending? (up to 3 e-mails get sent per script execution though)
- should I create a local queue and an 'every 5 minutes cron job' to parse the queue and send?
- or has some else found a better way of dealing with cross platform mailers?
Input, as always, humbly welcomed.
cLive ;-)
ps - IANAL (I Am Not A Laccolith)
Back to
Seekers of Perl Wisdom