From 272210ab5d54986f9589fc60c87baa28d207453b Mon Sep 17 00:00:00 2001 From: Robert Morrison Date: Thu, 26 Sep 2024 01:04:57 -0700 Subject: [PATCH] fix: pass pool_timer to hyper_util to enable the idle cleanup task --- src/async_impl/client.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/async_impl/client.rs b/src/async_impl/client.rs index 9a34f3fb6..5903329fa 100644 --- a/src/async_impl/client.rs +++ b/src/async_impl/client.rs @@ -727,7 +727,10 @@ impl ClientBuilder { } #[cfg(not(target_arch = "wasm32"))] - builder.timer(hyper_util::rt::TokioTimer::new()); + { + builder.timer(hyper_util::rt::TokioTimer::new()); + builder.pool_timer(hyper_util::rt::TokioTimer::new()); + } builder.pool_idle_timeout(config.pool_idle_timeout); builder.pool_max_idle_per_host(config.pool_max_idle_per_host); connector.set_keepalive(config.tcp_keepalive);