Hi all,

I'm trying to figure out a way to send batch emails in my distributed Spring application. The application runs on a number of Tomcat instances and what I need is a way whereby only one instance sends the batch emails via a Quart scheduled job. Previously I've managed this by configuring the application so that although all instances run the scheduled task, only the one running on a specific machine actually executes successfully. The problem with this though is that you have a single point of failure. What I'd like is for a server to take over the email sending if another one isn't running.

Any ideas or pointers?

Thanks

Nick