Currently Kafka clients resolve a symbolic hostname using
new InetSocketAddress(String hostname, int port)
which only picks one IP address even if the DNS has multiple records for the hostname, as it calls
For some environments where the hostnames are mapped by the DNS to multiple IPs, e.g. in clouds where the IPs point to the external load balancers, it would be preferable that the client, on failing to connect to one of the IPs, would try the other ones before giving up the connection.
KAFKA-7755 Kubernetes - Kafka clients are resolving DNS entries only one time
KAFKA-2036 Consumer and broker have different networks
- links to