I’m using haproxy to load balance http servers.
Each server for specific backend is set with maxconn=1
Also, I’m using dns discovery to find the servers for the backend.
The behavior I’m seeing is, when multiple new instances of the service spawn (with autoscaling) few servers receive more than 1 request, not meeting the max on requirement.
Could you please share haproxy logs, which illustrate with this behavior and your back-end configuration ?
Server maxconn limits the number of concurrent requests in case of HTTP.
You can also control it more precisely with stats page.
Here are more details how to enable it and explanations on stats counters: