HAProxy SRV Record Limit of 5

I am using HAproxy 2.8.1 for loadbalancing a set of backend statefulset pods in Kubernetes. Does anyone knows if there is a HAProxy limit for SRV records while using server-templates, it seems it is not able to return more than 5 SRV records and requests are not getting forwarded to other statefulset pods beyond 5. Did a nslookup from haproxy container and it returns only 5 records while if we do the same nslookup from a different container its able to return full set of SRV records corresponding to pods managed by the kubernetes headless service.

Haproxy does not have anything to do with the nslookup in your container. Haproxy is just an application running in that container.

You’d have to troubleshoot whatever container setup you have there.

Yes nothing to do with nslookup it was just to test and debug. I guess the issue may be running any docker image for haproxy container doesn’t forward request to more than 5 statefulsets that are scaled using HPA and haproxy docker container is unable to get statefulset pods dns via headless service using server-templates.