mperham / connection_pool

Generic connection pooling for Ruby
MIT License
1.63k stars 143 forks source link

Do not increment `@created` object counter in `TimedStack` before object creation actually succeeds #73

Closed mylesmegyesi closed 9 years ago

mylesmegyesi commented 9 years ago

In the case that object creation throws an exception, the @created counter was still being incremented, effectively taking up a slot in the pool forever.

mylesmegyesi commented 9 years ago

Any chance I could get the released as a minor version? It's causing a lot of pain in our system right now.

mperham commented 9 years ago

I'd like to wait another week or two. You can do this in your Gemfile:

gem 'connection_pool', github: 'mperham/connection_pool'
mylesmegyesi commented 9 years ago

Thanks. Unfortunately, connection_pool is a dependency of a gem, not an application. So, until it is released, I won't be able to update the gemspec.