Order placement inconsistent latency on the same websocket channel.

Hello all!

I’ve been experimenting around with the new user_data websocket endpoint and observed a very strange pattern in the latencies for the incoming order responses from binance. All the following measurements were taken from one single machine using a single websocket channel.

So here’s the distribution of latencies (computed as tcp_ack - send_time):
[1] Plots#1
Everything looks normal here, nothing unusual, pretty stable and great variance.

But here comes the strange part, on the receiving side (computed as receive_time - exchange_time):
[1] Plots#2
We can observed two clear separate sets of latencies. I first expected them to be caused by the network route, but the fact that the order requests sent are consistent kinda contradicts this assumption.

Does anyone know causes this? Is there a ‘cure’ :)? Is there some kind of load balancing or retry on Binance’ side? What’s even more suspicious is the obvious 50-50 distribution between the two clusters. I couldn’t find anything in my orders that could classify them in the slow or fast cluster.

P. S.: After observing this, I also did the same measurements for the http endpoint and I did observe the same distribution, but with a lot more noise [1] Plots#3.

Can’t upload media or multiple links :(, sorry…

[1] Plots

what did you do in Plots 1 & 2 that had different results?
what is the “latency” time, in ms?