Let say there are two backend servers with maxconn option set to 1 and with round-robin routing strategy. This means that at times only two requests could be processed and others are put on queue.
Lets say the web app makes two separate requests in a 60 second time frame to get needed data to render the page with good user experience. What happens when in between these two requests many other clients requests arrive which got queued and later timeout? Does this mean that second request of the first user has a bigger chance to time out because of already queued other users requests? Do I understand correctly that haproxy request queuing works like FIFO? If yes, this could lead to bad experience for all visitors on very high load because ALL users will experience that some requests are completed, but some timeout. I would prefer that some users experience faultless experience without any timeouts, and other clients get timeout on first request if there aren’t enough slots left.
On very high load I know that I will not be able to handle all request, but I want at least make good experience for limited number of users (even better if I could prioritise clients by custom header). Maybe it could be some queue by user’s header or connection to hold connection per client while active e.g. for 1 minute in between requests, so all request could be processed without putting to queue, but put all requests of new clients while limited number of clients are served.
Any suggestions on such configuration possible with haproxy?