community
community copied to clipboard
[BUG] Slack Terraform CI automation timeouts
Describe the bug.
@Shurtu-gal did an excellent job with automating the creation and maintainability of AsyncAPI Slack channels and user groups. See https://github.com/asyncapi/community/issues/1072
However, we faced a blocker issue that makes the Terraform manifest to fail due to timeouts requesting Slack API.
The TF provider is not optimized at all. I have the feeling this code is being executed per each managed Usergroup whenever TF wants to refresh its state: https://github.com/pablovarela/terraform-provider-slack/blob/master/slack/resource_usergroup.go#L108-L128, so potentially we are calling the usergroups.list API method on each usergroup we have.
Expected behavior
I believe we could do some work on the provider repo (it's written in go, seems easy to read and understand at a glance) so we can implement some caching or whatever mechanism we decide. But in short term, I can't see how to fix it.
Screenshots
How to Reproduce
terraform apply
with the proper Slack Token configured (ask @derberg or me)
🥦 Browser
None
👀 Have you checked for similar open issues?
- [X] I checked and didn't find similar issue
🏢 Have you read the Contributing Guidelines?
- [X] I have read the Contributing Guidelines
Are you willing to work on this issue ?
None