-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add throttling option to campaigns API? #167
Comments
Hey @jmensch1, Thank you for the feedback! Would disabling webhooks for messages generated by the campaign be a viable option for you in this case? |
Hi @kanat, thanks for getting back to me. I saw the Jake |
Hi @jmensch1, Thank you for the update! |
Hi @kanat, I didn't know about that. It's a nice solution and would probably work from a technical point of view. The only problem is that all of our infrastructure is on GCP, and I don't think there would be a lot of interest in opening an account with AWS just for this purpose. Just so you know, when Stream shut down the first Campaigns api a few months ago, I wrote a service for sending campaigns using the regular Messaging api. It's a bit slow, since I need to stay under the rate limit, but it's working well enough. So it's not urgent for us to use the new Campaigns api right now. I might try it again at some point in the future. Thanks |
Per your docs, the Campaigns api sends messages at a rate of about 60000 per minute. (https://getstream.io/chat/docs/python/campaign_api/?language=python). Would it be possible to add a throttling option so that these messages get sent more slowly, at a rate specified by the user?
The reason is that we have a server that handles the webhooks for new message events. Normally that server handles at most a few hundred events per minute. If that number were to jump to 60000 / minute without any ramp-up time, the server would undoubtedly crash.
The text was updated successfully, but these errors were encountered: