I am coding a notification system. The clients will get notification from the server by http-long-polling(Spring async requests with DeferredResult). Now I need to limit the total connection the server can hold and the max connection count a client should keep. All connections out of quota will be reject with status code 429 to many reuqests.
I am trying to do this with spring-cloud and zuul. But I have no idea about hou to intecept the lifecycle of an async request with zuul.