I need to communicate with server by HTTPS.
for example, my server host is fapi.binance.com
. This host is an AWS cluster, which means it is mapped into several real server. each server has it own IP address.
Here is the result of nslookup
:
root:~ # nslookup fapi.binance.com [13:56:17]Server: 172.31.0.2Address: 172.31.0.2#53Non-authoritative answer:fapi.binance.com canonical name = tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.com.Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 54.150.142.177Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 52.197.102.163Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 35.73.123.186Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 54.168.53.237Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 18.178.134.175Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 52.196.216.168Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 54.250.126.1Name: tf-futures-prod-fapi-2-alb-2110254405.ap-northeast-1.elb.amazonaws.comAddress: 52.68.184.115
As above, this cluster has 8 IP addresses (server).
I found the HTTPS requests' latency is different between these 8.
But every time, the TCP connected IP address is not fixed.
So, is there any methods I can use to connect with the fastest IP address?