GetStream / stream-js

JS / Browser Client - Build Activity Feeds & Streams with GetStream.io
https://getstream.io
BSD 3-Clause "New" or "Revised" License
329 stars 110 forks source link

add throttle option #219

Open mikestaub opened 5 years ago

mikestaub commented 5 years ago

The rate limits are described here. Why not create an option that will automatically throttle the internal calls to those functions instead of having all consumers of this library wrap them manually?

https://getstream.io/docs/js/#rate-limiting

tbarbugli commented 5 years ago

Throttling is worse than an immediate and loud error in almost all cases beside automated flows (eg. data imports, auto-follow, data sync). For critical paths like reading users' feeds (or anything transactional), throttling does not help. Apps on Stream can request rate limit to be increased by reaching out to support@getstream.io

What's your use-case for using Stream?

mikestaub commented 5 years ago

My use case is a standard social networking app. I am hitting throttling errors during my integration tests.