-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Slack integration - Hitting Slack rate limit when using API's to create alerts gives wrong error message #80443
Comments
Routing to @getsentry/product-owners-settings-integrations for triage ⏲️ |
Auto-routing to @getsentry/product-owners-settings-integrations for triage ⏲️ |
Yeah, it's very reasonable. Thanks for the feedback. Added it to the team backlog. |
Hey @sentaur-athena, one thing I wanted to know more about is the usage of the ChannelID. |
@Angelodaniel It may or may not help. You might be reaching workspace limit. From Slacks docs:
|
extra details: when creating multiple alerts that post to same channel ID, on first alerts I do not face rate-limit, while on last alerts I do. As all alerts used same slack channel ID, maybe there can be internal Sentry caching for Slack integration? I'm facing this issue every week, and adding extra sleeps to not trigger rate limiting and waiting 1-2h to update all alerts is far from optimal |
@keradus what do you mean by the last alert? Is it always the same alert that rate limits? Is it the last in order of time or creation? |
@keradus the ratelimiting for the creation API is 50+ per minute so I don't think there's anyway to manually hit it. We will add more logging to investigate this further. |
Imagine that you have an automation to maintain 200 alerts for your 100 projects (real numbers for my Sentry contract), and then imagine each of those alerts having configured action to send alert msg to the very same Slack channel, you have 200 API calls. in meanwhile, thanks for the info about current rate-limiting to be 50/minute. It will help groom speed of API requests on our automation. |
Got it. Yeah makes sense to add some caching and read the response instead of calling the API again. I'll add this improvement to our backlog and post an update when I have a timeline. |
Environment
SaaS (https://sentry.io/)
Steps to Reproduce
Expected Result
When Slack is rate limiting the requests it should be clear within Sentry users why it has been failing.
Actual Result
Error message is: (ERROR): failed to update transactionsVolume, 400 given. Received: {"nonFieldErrors":["Could not retrieve Slack channel information."]}
While internally we get "The Slack API responded with {'ok': False, 'error': 'ratelimited'}"
We likely will need to add a rate limit check here.
Product Area
Settings - Integrations
Link
No response
DSN
No response
Version
No response
┆Issue is synchronized with this Jira Improvement by Unito
The text was updated successfully, but these errors were encountered: