-
Notifications
You must be signed in to change notification settings - Fork 84
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
Optimization: Reuse HTTPClient / DynamicClient in reconcile #371
Optimization: Reuse HTTPClient / DynamicClient in reconcile #371
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: justinsb The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
c32008e
to
49d6914
Compare
Should be slightly more efficient via better HTTP connection reuse.
49d6914
to
7d9d368
Compare
cc @cheftako - as requested re reusing the DynamicClient; I think the answer is that the caller should try to provide a cached DynamicClient, because client-go is more efficient if we can reuse the |
First of all, this looks good. BTW, I am not sure about my comment is related with this PR. 🤔 On the other hand, |
Great point @atoato88, and you're absolutely right. I added a commit that should also reuse the dynamic-client in the direct applier. (I don't think we can practically reuse it in the exec applier.) I also noticed that we probably should be trying to reuse the http client here, but I think I'll have to send a separate PR for that one! |
/lgtm |
Should be slightly more efficient via better HTTP connection reuse.