ChimeraCoder / anaconda

A Go client library for the Twitter 1.1 API
MIT License
1.14k stars 247 forks source link

How to get reconnection data from streaming channel? #192

Open gnobre opened 7 years ago

gnobre commented 7 years ago

I need to know when the reconnection happened so I can use the Search API to back fill the missing data (last tweet before reconnection & first tweet after reconnection would do). I tried shutting down my internet and the stream just reconnects once the internet is available again without throwing any errors, neither log messages.

cention-mujibur-rahman commented 6 years ago

@gnobre I think you are asking this: https://godoc.org/github.com/ChimeraCoder/anaconda#NewTCPIPErrBackoff it tries to reconnect by every 250ms each attempt, up to 16 seconds its increased exponentially until reconnect successful.