开发者

Is an e-mail queue necessary in an e-mail-heavy web app?

In a couple of recent projects, I've written an e-mail queue as a database table that is checked every minute by a cronjob. The cron script waits a few seconds in between sends.

The reason I did this was because I read somewhere that it helps your e-mail not end up in the spam folder if it's not blasted out from the sa开发者_如何转开发me server all at once. I don't remember where I read it.

What do you think? Should I just mail things immediately or is an e-mail queue a good idea?

What are some pros and cons to this approach?

EDIT: Added last paragraph.


Do you have control over your SMTP server? If so, then there's no point in doing an email queue PHP-side. The SMTP server will already have queueing capabilities. If you're worried about blasting a particular receiving server, you can always turn on your SMTP server's throttling (if it has it), something along these lines.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜