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

(GH-2518) Add read-timeout config for PCP transport #2529

Merged
merged 1 commit into from
Jan 14, 2021

Conversation

lucywyman
Copy link
Contributor

@lucywyman lucywyman commented Jan 9, 2021

This adds a read-timeout configuration setting for the PCP transport,
which accepts an integer and passes the configuration to
OrchestratorClient.new(). Although the option is an integer, it
should be nil if a value is not provided, as there's no static default
for Net::Http::Persistent#read_timeout, so we should not set one
unless it's configured. This allows users to configure either failing
quickly if the Orchestrator is busy (such as during code deploys), or to
extend the time if they'd like to wait for the jobs to finish.
read-timeout configures the length of time to wait for a response from
the Orchestrator before raising a timeout error when making HTTP
requests.

Relies on:

!feature

  • Add read-timeout configuration option for PCP transport (#2518)

    Users can now configure a read-timeout for HTTP requests to the
    Orchestrator, which defines how long to wait for a response before
    raising a Timeout error.

@lucywyman lucywyman marked this pull request as ready for review January 11, 2021 17:12
@lucywyman lucywyman requested a review from a team as a code owner January 11, 2021 17:12
@beechtom beechtom linked an issue Jan 11, 2021 that may be closed by this pull request
This adds a `read-timeout` configuration setting for the PCP transport,
which accepts an integer and passes the configuration to
`OrchestratorClient.new()`. Although the option is an integer, it
should be nil if a value is not provided, as there's no static default
for `Net::Http::Persistent#read_timeout`, so we should not set one
unless it's configured. This allows users to configure either failing
quickly if the Orchestrator is busy (such as during code deploys), or to
extend the time if they'd like to wait for the jobs to finish.
`read-timeout` configures the length of time to wait for a response from
the Orchestrator before raising a timeout error when making HTTP
requests.

!feature

* **Add read-timeout configuration option for PCP transport** ([puppetlabs#2518](puppetlabs#2518))

  Users can now configure a `read-timeout` for HTTP requests to the
  Orchestrator, which defines how long to wait for a response before
  raising a Timeout error.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make timeouts configurable for the PCP transport
2 participants