Skip to content
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

api: use cleanhttp.DefaultPooledTransport for default API client #12492

Merged
merged 1 commit into from
Apr 6, 2022

Conversation

tgross
Copy link
Member

@tgross tgross commented Apr 6, 2022

We expect every Nomad API client to use a single connection to any
given agent, so take advantage of keep-alive by switching the default
transport to DefaultPooledClient. Provide a facility to close idle
connections for testing purposes.

Restores the previously reverted #12409 (cc @benbuzbee)

We expect every Nomad API client to use a single connection to any
given agent, so take advantage of keep-alive by switching the default
transport to `DefaultPooledClient`. Provide a facility to close idle
connections for testing purposes.

Restores the previously reverted #12409

Co-authored-by: Ben Buzbee <bbuzbee@cloudflare.com>
Copy link
Contributor

@DerekStrickland DerekStrickland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is safe, and it looks like the blast radius is constrained to Operator.

:shipit:

@tgross tgross merged commit daa9824 into main Apr 6, 2022
@tgross tgross deleted the api-default-pooled-client branch April 6, 2022 20:14
@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 22, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
theme/api HTTP API and SDK issues type/enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants