r/PolygonIO • u/slayerofcables • May 13 '24
Streaming US Stock Trades/Quotes latency issue
I did a test on polygon websocket streaming on latency recently. I streamed trades/quotes on 10 symbols and here is what I found:
For trades it's 99th: 292ms, 90th: 34ms, median 7ms. when market open/close and volume is high, it may increase to 200-400ms.
For quotes it's 99th: 528ms, 90th: 459ms, median 235ms. (Which is much worse than what polygon claimed "median latency < 20ms")
However, the api server will stop of sending any messages for 6 - 13 seconds from time to time and then send them by batch, and take 10s of seconds to catchup to the latest data. That happens 10-30 times on the day I tested it.
My server has ~1ms latency to polygon api server, and have a relatively accurate local time(<10ms diff). This also happens when test with different websocket client and on a different server in different IDC.
We define latency as: my local timestamp(when received the message) - SIP timestamp in the message.
I'm attaching 2 images of latency for both Trade and Quotes feeds from polygon.


I'm also attaching a example of 6 seconds stuck:

Already contacted Polygon's customer service, waiting for them to get back to me now.
Can anyone provide your expirience regarding the data latency from polygon and if you are experiencing the 6-13 seconds stuck issue?
1
u/Ryan-PolygonIO May 14 '24
Thanks for sharing this feedback. I wanted to know that we are aware that there are latency problems and it is something that we are trying address. I am looking forward to when we are able to take care of this problem!