Re: SMTP vs mail()

From: Date: Sat, 12 Jan 2008 10:28:00 +0000
Subject: Re: SMTP vs mail()
References: 1 2 3 4  Groups: php.general 
Request: Send a blank email to php-general+get-267139@lists.php.net to get a copy of this message
Assuming you're talking delivery to a local MTA (which will subsequently do the remote delivery), is speed really important?
For the amount of email I'm looking at (1000s, growing), yes.
Hmm, that's not quite what I was thinking of. The amount of emails to be delivered does not in my opinion affect how fast it needs to happen. Your local MTA will take a while to deliver those emails anyway, so the time from script to user is mostly dependent on that, which means you're left with reducing the time from script to MTA. If you need to finish the script fast (in order for some user-intercation to continue perhaps), I would would just detach the script and carry on.
Sorry, yes the time of delivery is not so important as the time to pump the messages to the MTA. As long as the MTA has them and they get delivered in a reasonable time frame I'm happy. The application is all about mail delivery and the script has to return immediately, so I'll be launching a separate process to insert the addresses into a minimal "mail_queue" table in my db, and then a 5 minutely cron script which will pass them to the MTA. -- Richard Heyes http://www.websupportsolutions.co.uk Knowledge Base and HelpDesk software that can cut the cost of online support ** NOW OFFERING FREE ACCOUNTS TO CHARITIES AND NON-PROFITS **

« previous php.general (#267139) next »