instance method
disconnect!
Ruby on Rails 5.2.8.1
Since v2.2.3Signature
disconnect!()
Disconnects all connections in the pool, and clears the pool.
The pool first tries to gain ownership of all connections. If unable to do so within a timeout interval (default duration is spec.config[:checkout_timeout] * 2 seconds), then the pool is forcefully disconnected without any regard for other connection owning threads.
Source
# File activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb, line 469
def disconnect!
disconnect(false)
end
Defined in activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb line 469
· View on GitHub
· Improve this page
· Find usages on GitHub