Skip to content

Commit

Permalink
Change ConnectionPool size to not use an iterator
Browse files Browse the repository at this point in the history
  • Loading branch information
mullermp committed Apr 30, 2024
1 parent 843e96e commit e7694e0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
2 changes: 2 additions & 0 deletions gems/aws-sdk-core/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
Unreleased Changes
------------------

* Issue - Fix issue where `ConnectionPool` size iteration would prevent a new key from being added to the pool.

3.194.0 (2024-04-30)
------------------

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,11 +119,7 @@ def session_for(endpoint, &block)
# pool, not counting those currently in use.
def size
@pool_mutex.synchronize do
size = 0
@pool.each_pair do |endpoint,sessions|
size += sessions.size
end
size
@pool.values.flatten.size
end
end

Expand Down

0 comments on commit e7694e0

Please sign in to comment.