Hi,
I am using websocket streams for trades, tickers and user data. I want to be sure all streams are always connected and remain connected. In order to check this, I have built a reconnection system, which checks every x minutes whether or not a ping or pong has been received in the minutes before it. If it has been too long ago, the websocket will close and try to reconnect. This system works fine, but I am noticing some irregular behaviour here.
Sometimes, I receive pings and pongs successfully for multiple hours in a row, but then all of a sudden, they stop coming in, which is where my reconnection system comes in. Is this common or is there another reliable way to check if the connection is still active?
Thanks in advance.