Closed datakurre closed 4 years ago
@datakurre problem was that collecting all the users and preparing personalized email for 3000+ recipients took quite some time and the risk that the newsletter editor would do something "dangerous" was too big. Also there were timeouts on nginx which looked like an error and editors were tempted to resend the same newsletter... So we decoupled the preparation of the sendout into a separate job.
@agitator Thanks. So, there was much more that just sending email. 👍
I'm working already on a dramatiq based version, for WSGI. But it's plugable anyway ;)
Nice. Broker connections are always tricky. Probably even more so with WSGI. And two phase commit should somehow to be taken account so that connections is tested during the first phase so that the second phase could no longer fail... Interest to see how it works out. I'm probably thinking in too complex :)
@MrTango I was surprised to to see "asynchronous sendout" using collective.taskqueue. Does it do something that just using asynchronous queuing feature of Products.MailHost does not?
https://pypi.org/project/Products.MailHost/
(That said, I have no idea, if MailHost queue works any better than taskqueue [it does not] with WSGI. I assume it needs a separate zope.sendmail daemon to be run to send the created queue from disk.)