You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey there. Thanks for making such an awesome library. I'll be happy to help resolve this but would like some input regarding how you would like it to be handled.
It seems like pretty consistently, after subscribing to the ticker on the Websocket v2 API (for starters, I'm just using "BTC/USD" and "ETH/USD"), I will get data for several hours hours then it will suddenly stop. I practically copied and pasted your example from the docs as a starting point:
pubasyncfnsubscribe(db:&DatabaseConnection,symbols:Vec<String>) -> anyhow::Result<()>{letmut client = kraken_ws_client::connect_public().await.expect("cannot connect");let req = if symbols.is_empty(){SubscribeTickerRequest::all()}else{SubscribeTickerRequest::new(symbols)};
client.send(req).await.expect("cannot send request");whileletSome(event) = client.ticker_events().next().await{for ticker_data in event.data.iter(){// fine for some hours}}// Code does not reach here after the stallOk(())}
So it gets stuck in the ticker events loop. After it stalled, it held the websocket open for seemingly forever (I killed it at least 8 hours later manually). One time it stalled after 2 hours, currently it's been running at 4 with no issues but I'm pretty sure it will stall at some point. Is this something you've run into? Do you have an easy workaround?
The text was updated successfully, but these errors were encountered:
We could add a mechanism to check the heartbeat messages, and if they don't arrive for e.g. 10s, it should trigger a re-connection. That would make the client more robust.
Hey there. Thanks for making such an awesome library. I'll be happy to help resolve this but would like some input regarding how you would like it to be handled.
It seems like pretty consistently, after subscribing to the ticker on the Websocket v2 API (for starters, I'm just using "BTC/USD" and "ETH/USD"), I will get data for several hours hours then it will suddenly stop. I practically copied and pasted your example from the docs as a starting point:
So it gets stuck in the ticker events loop. After it stalled, it held the websocket open for seemingly forever (I killed it at least 8 hours later manually). One time it stalled after 2 hours, currently it's been running at 4 with no issues but I'm pretty sure it will stall at some point. Is this something you've run into? Do you have an easy workaround?
The text was updated successfully, but these errors were encountered: