Support for bulk email sending

Issue #1 resolved
Dan Jacob
repo owner created an issue

A Relay class which handles mutliple messages per connection. This would be useful when sending bulk email messages e.g in a script or cronjob.

It would be used like this:

{{{

!python

from flaskext.mail import Message, PersistentRelay

def send_bulk_emails(users, relay): for user in users: message = Message(recipients=[user.email]) # configure message message.send(relay=relay)

relay = PersistentRelay()

with relay.connect(): send_bulk_emails(users, relay)

}}}