I am able to successfully implement Server Sent Events, with Spring framework. I have a use case, in which my application [SSE-Publisher] will get notification from some third party application over the rest api. And on receipt of these notification, it will be broadcasting events to the connected clients.
This works for single instance of SSE-Publisher and without load balancer.
If I have load balancer between SSE-Publisher and external application. Clients can subscribe to sse events on any instances of SSE-Publisher. Now, when a notification is received from external application and it is routed to arbitary SSE-Publisher, the instance doesn't know how to publish the events.
So, in this case, can we store this SSEmitter object to some external store like MongoDB / Redis?
And later on, any SSE-Publisher can pull it from the backend and publish the event.