Set `pool_idle_timeout` at 90 seconds for default hyper client (#4284)
## Motivation and Context <!--- Why is this change required? What problem does it solve? --> <!--- If it fixes an open issue, please link to the issue here --> Fixes: https://github.com/smithy-lang/smithy-rs/issues/4282 ## Description <!--- Describe your changes in detail --> Updating our default Hyper client to be configured with a [pool_timer](https://docs.rs/hyper-util/latest/hyper_util/client/legacy/struct.Builder.html#method.pool_timer) and a [pool_idle_timeout](https://docs.rs/hyper-util/latest/hyper_util/client/legacy/struct.Builder.html#method.pool_idle_timeout) value of 90 seconds. Prior to Hyper going 1.0 and the legacy client moving into its own crate a `pool_timer` was not required. Now the pool won't timeout idle connections without one. The default value for the timeout in Hyper 0.14 was [90 seconds](https://docs.rs/hyper/0.14.32/hyper/client/struct.Builder.html#method.pool_idle_timeout), so we are copying that in our current settings. ## Testing <!--- Please describe in detail how you tested your changes --> <!--- Include details of your testing environment, and the tests you ran to --> <!--- see how your change affects other areas of the code, etc. --> This is difficult to test at the moment because Hyper does not support plugging in your own pool implementation, so we cannot instrument the pool itself. There has been some movement towards allowing that, so when that happens we could add tests for this behavior. For the time being we will have to be satisfied that the Hyper client tests this itself. ## Checklist <!--- If a checkbox below is not applicable, then please DELETE it rather than leaving it unchecked --> - [x] For changes to the smithy-rs codegen or runtime crates, I have created a changelog entry Markdown file in the `.changelog` directory, specifying "client," "server," or both in the `applies_to` key. ---- _By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice._
Loading
Please sign in to comment