• Resolved valeriuc

    (@valeriuc)


    Hello Nikolai,

    i run a blog and i have about 100 subscribers and my hosting provider has a 70 email / hour limit. How can i send the emails in batches or somehow limit the emails sent per hour from this plugin. Can i have a workaround this.

    Thanks,
    Valeriu

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author nstaeger

    (@nstaeger)

    Hi valeriuc,

    that’s an interesting use-case I did not think of. Thanks for bringing this up. As of now the plugin does not support your use-case.

    For a quick fix, you could modify one line of code yourself. The Job that sends the mails, always sends a batch of mails in one request. The size of this batch is configurable by setting the “Number of emails to be send per request”. When this number of mails was send, the job will be rescheduled to send the next batch at least to seconds later. This interval can be changed manually by editing the following line of code to “add” more than two seconds, e.g. 600 seconds to send the next batch after 10 minutes:

    https://github.com/nstaeger/wp-post-email-notification/blob/master/src/Model/JobModel.php#L126

    If you do not want to do this on your own, you will need to wait for a future release. I put it on the todo list:

    https://github.com/nstaeger/wp-post-email-notification/issues/12

    Best,
    Nicolai

    Thread Starter valeriuc

    (@valeriuc)

    For the moment the hosting provider raised my limit to 150 mail/ hour.
    But still I will modify the code and wait for the update.

    For example is ok to use the following config? Number of emails to be send per request=100, wait time 3600s?
    Send a batch of 100 then wait for 1 hour and send another batch of 100.

    Thanks!

    • This reply was modified 7 years, 6 months ago by valeriuc.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Exceeded the max emails per hour’ is closed to new replies.