If I submit a new request ( email@example.com to firstname.lastname@example.org ) before the first request completes, system will reject it.
I can easily do a sychronization on the source email address like this:
However this will not work in a cluster of webservers. What are my alternatives ?
Joined: Jan 28, 2005
I assume if you're using a cluster of web servers you will have some sort of database to store information in?
If so, you could have a database table to hold pending request details.
Each time you receive a request to send an email you would check if there is already a corresponding row in the pending request table. If there is you reject it. If not, you add a row for it and then send the email.
When the email is sent you delete the row from the pending request table.