-
-
Notifications
You must be signed in to change notification settings - Fork 170
Closed
Labels
infoInformationsInformations
Description
Its important to understand, that the data between a disconnect and a reconnect is LOST!
And reconnects take place! Regarding to https://github.com/binance-exchange/binance-official-api-docs/blob/master/web-socket-streams.md#general-wss-information disconnects have to be expected every 24h.
A single connection to stream.binance.com is only valid for 24 hours; expect to be disconnected at the 24 hour mark
So you have to find a strategy for that!
Ideas to handle this are:
- replace_stream(): start a new stream with the same settings and stop the old one, as soon the new received its first data. This could be scheduled and made automatic, but therefore we have to write a new method, which is not done yet!
- stream the same data through 2 ident websocket connections on one system or better, on different systems
- download missing data via REST after a reconnect.
It would be cool to discuss this as a community, do brainstorming and define a best practise solution. Then we can extend the library with helping features to implement the best practise solution.
I look forward to good suggestions!
Best regards,
Oliver
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
infoInformationsInformations