Skip to content

Commit 162cbfd

Browse files
committed
pinns eviction loop frequency
1 parent 159a1ba commit 162cbfd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/sshkit/backends/connection_pool.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def inspect
2121

2222
# The ConnectionPool caches connections and allows them to be reused, so long as
2323
# the reuse happens within the `idle_timeout` period. Timed out connections are
24-
# closed, forcing a new connection to be used in that case.
24+
# eventually closed, forcing a new connection to be used in that case.
2525
#
2626
# Additionally, a background thread is started to check for abandoned
2727
# connections that have timed out without any attempt at being reused. These
@@ -137,7 +137,7 @@ def run_eviction_loop
137137
process_deferred_close
138138

139139
# Periodically sweep all Caches to evict stale connections
140-
sleep([idle_timeout, 5].min)
140+
sleep(5)
141141
caches.values.each(&:evict)
142142
end
143143
end

0 commit comments

Comments
 (0)