
On Sun, Sep 21, 2003 at 10:24:31AM +0200, William Dode wrote:
Jp Calderone <exarkun@intarweb.us> writes:
On Sat, Sep 20, 2003 at 01:36:20PM +0200, William Dode wrote:
Hi,
Is it a good way to call smtp.sendmail() for sending a lot of mails (it's for a scrabble game, not spam !) It will connect and deconect for each mail isn't it ?
twisted.protocols.smtp.sendmail() is better
It's what i use. But it's very slow and it call each time reactor.connect...
Unless you are sending all the mail to users on a single host or you have a smarthost which will relay your mail, you must make multiple connections. Of course, if you're sending to a smart host, it just means that that server will have to go out and make connections to multiple hosts... So you're not saving any work, you're just pushing it onto someone else. Jp -- Seduced, shaggy Samson snored. She scissored short. Sorely shorn, Soon shackled slave, Samson sighed, Silently scheming, Sightlessly seeking Some savage, spectacular suicide. -- Stanislaw Lem, "Cyberiad"