binance / binance-connector-dotnet

Lightweight connector for integration with Binance API
MIT License
207 stars 69 forks source link

where is pong response? #25

Closed hrshfa closed 2 years ago

hrshfa commented 2 years ago

by your guide: "Heartbeat Once connected, the websocket server sends a ping frame every 3 minutes and requires a response pong frame back within a 10 minutes period. This package handles the pong responses automatically." but i cannot this handle code in BinanceWebSocket.cs or BinanceWebSocketHandler.cs please guide me , where is this handle code? i'm getting !bookTicker stream by socket but after a period of time this is cut off !!!

tantialex commented 2 years ago

BinanceWebSocketHandler wraps around a System.Net.WebSockets.ClientWebSocket which implicitly handles the ping pong framework.

Source Code from DotNET. https://github.com/dotnet/runtime/blob/7cbf0a7011813cb84c6c858ef19acb770daa777e/src/libraries/Common/src/System/Net/WebSockets/ManagedWebSocket.cs#L886

i'm getting !bookTicker stream by socket but after a period of time this is cut off !!!

Is this behaviour consistent with other streams?