This is documented in painful detail here: http://dev.twitter.com/pages/streaming_api_concepts#updating-filter-predicates .
If you connect a second time, you should get a TCP Close or Reset on the first connection. It sounds like your client library isn't detecting the connection close. -John Kalucki http://twitter.com/jkalucki Twitter, Inc. On Thu, Feb 24, 2011 at 1:08 PM, Josiah Carlson <[email protected]>wrote: > Now that I've got OAuth with statuses/follow.json working, I've been > working through building a small part of our app. > > Part of the streaming API docs state that only one connection is allowed > (reasonable). Upon making a second connection, the first no longer receives > any data (not even anti-timeout newlines), nor does it get connected by the > server. On my end of things, I've written an async client which can detect > such a condition (it watches a shared Redis key looking for a changed state > when it doesn't receive any data for a while), and automatically > disconnects. > > The streaming API docs also state that repeated reconnections, etc., are > frowned upon and may result in banning. > > My question is simple: how often can I reconnect to follow different > people/keywords? Obviously ten times a second is well beyond reasonable and > would probably get us banned in seconds. But isat most once every 5 minutes > okay? At most once every minute? At what level would we be safe? > > Thank you, > - Josiah > > -- > Twitter developer documentation and resources: http://dev.twitter.com/doc > API updates via Twitter: http://twitter.com/twitterapi > Issues/Enhancements Tracker: > http://code.google.com/p/twitter-api/issues/list > Change your membership to this group: > http://groups.google.com/group/twitter-development-talk > -- Twitter developer documentation and resources: http://dev.twitter.com/doc API updates via Twitter: http://twitter.com/twitterapi Issues/Enhancements Tracker: http://code.google.com/p/twitter-api/issues/list Change your membership to this group: http://groups.google.com/group/twitter-development-talk
