I am currently attempting to decrease latency when calling the orderbook with the Binance API.
I am getting a ping of ~7ms but the orderbook call takes ~200ms to download. I am using a VM hosted in the same AWS farm that Binance uses, and I am running on a network speed of ~800mbps. I do not understand why the orderbook call takes nearly two orders of magnitude more time to receive than the time it takes to ping the server when the size of the orderbook is relatively small.
Any help or insight into either the network, or restrictions imposed by Binance would be greatly appreciated.
tcpfump
on the interface being used. You can then open the capture file in Wireshark to see if there are any red flags. – Liam Kelly Jan 19 '18 at 13:52