method

with_exclusively_acquired_all_connections

rails latest stable - Class: ActiveRecord::ConnectionAdapters::ConnectionPool
with_exclusively_acquired_all_connections(raise_on_acquisition_timeout = true)
private

Take control of all existing connections so a “group” action such as reload/disconnect can be performed safely. It is no longer enough to wrap it in synchronize because some pool’s actions are allowed to be performed outside of the main synchronize block.