-
Notifications
You must be signed in to change notification settings - Fork 17
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
Rate limit handling #137
Comments
Hey @irizzant, The See #81 I am still experiencing some issues with these values also. I will share any finding I have |
Hi @lacroi-m-insta, For this reason I was more into the poll flag because it states in the doc:
But maybe I'm in the wrong direction, that's why I was asking for help. I'm going to further increase read_delay_ms, maybe if you have a suggested value it could be helpful |
Note that this is in millisecond so 500 is a GET request every 0.9~ seconds. I would suggest a minimum of 60000 These request allow to check for diff between the remote (github) and your crossplane resource |
Also I have only tested this for webhooks, I'm not sure if it takes into consideration other resources. |
Ok so read_delay_ms = 60000 means that the provider is going to wait 1 minute before reconciling the drift of each resource, did I understand correctly? So the poll flag will control how often to check for drift in general, while read_delay_ms controls how quick it reconcile the single resources, is that correct? I'm going to set read_delay_ms to 60000 as you suggested and see if anything changes |
I also created this slack thread to ask for help |
Does the provider Pod need to be restarted after applying the read_delay_ms change? |
I have tried to create a Repository resource after updating the read_delay_ms to 60000 but it takes a lot more time than before to create resources like that. After 15 minutes waiting the Repository was still not created. I'm curious to understand how long it takes for your resources to get synced with this setting. I don't know if this is just about tuning the read_delay_ms or if it's better to focus on the |
@lacroi-m-insta it looks like the problem was an infinite reconciliation loop of TeamMembership resources caused by a missing LateInitialize managementPolicy and crossplane/crossplane#5918. Without LateInitialize Crossplane sees the resource to be reconciled and queue it again and again in a infinite loop, see this Slack thread. After changing the TeamMembership and add back the LateInitialize I went from this: I now have a regular operations/sec rate and no more infinite workqueue with thousands of TeamMembership resources. Still I'm wondering, how much does all this scale? I think that when there are more and more resources to sync sooner or later you'll face rate limit issues |
Hello
I'm struggling to find if and how the provider supports Github rate limits handling.
We have many Github resources handled by this provider and what we're experiencing is that we hit Github rate limits.
What I think is the reason why is that we have some managed resources which cannot be created and sit there consuming reconciliation loops.
I tried to set write_delay_ms and read_delay_ms settings but it seems it doesn't fix the issue.
I also read about --max-reconcile-rate and --poll settings but I didn't know if the provider supported them until I dag into the code:
provider-upjet-github/cmd/provider/main.go
Lines 47 to 50 in bf4fac6
Anyway I'm not sure it that would help. Does the default values mean that there should be 100 concurrent API calls to Github every 10 minutes?
Any suggestion?
The text was updated successfully, but these errors were encountered: