nodemailer gmail connection closed with high number of mails

后端 未结 2 1196
执笔经年
执笔经年 2021-01-20 06:51

I have exactly the same issue as this post : Send multipe emails using nodemailer and gmail

When sending too many emails with nodemailer and gmail, I get a 421 error

2条回答
  •  独厮守ぢ
    2021-01-20 07:20

    Use Pooled SMTP : https://nodemailer.com/smtp/pooled/

    If pooling is used then Nodemailer keeps a fixed amount of connections open and sends the next message once a connection becomes available. It is mostly useful when you have a large number of messages that you want to send in batches or your provider allows you to only use a small amount of parallel connections.

提交回复
热议问题