instance method teardown_shared_connection_pool

Ruby on Rails 8.0.4

Since v6.0.6 Private

Available in: v6.0.6 v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Signature

teardown_shared_connection_pool()

No documentation comment.

Source
# File activerecord/lib/active_record/test_fixtures.rb, line 239
      def teardown_shared_connection_pool
        handler = ActiveRecord::Base.connection_handler

        @saved_pool_configs.each_pair do |name, shards|
          pool_manager = handler.send(:connection_name_to_pool_manager)[name]
          shards.each_pair do |shard_name, roles|
            roles.each_pair do |role, pool_config|
              next unless pool_manager.get_pool_config(role, shard_name)

              pool_manager.set_pool_config(role, shard_name, pool_config)
            end
          end
        end

        @saved_pool_configs.clear
      end

Defined in activerecord/lib/active_record/test_fixtures.rb line 239 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveRecord::TestFixtures

Type at least 2 characters to search.

↑↓ navigate · open · esc close