method
resolve_symbol_connection

v6.0.0 -
Show latest stable
-
0 notes -
Class: Resolver
- 1.0.0
- 1.1.6
- 1.2.6
- 2.0.3
- 2.1.0
- 2.2.1
- 2.3.8
- 3.0.0
- 3.0.9
- 3.1.0
- 3.2.1
- 3.2.8
- 3.2.13
- 4.0.2
- 4.1.8 (0)
- 4.2.1 (0)
- 4.2.7 (0)
- 4.2.9 (0)
- 5.0.0.1 (0)
- 5.1.7 (0)
- 5.2.3 (0)
- 6.0.0 (25)
- 6.1.3.1
- 6.1.7.7
- 7.0.0
- 7.1.3.2
- 7.1.3.4
- What's this?
resolve_symbol_connection(env_name, pool_name)
private
Takes the environment such as :production or :development and a pool name the corresponds to the name given by the connection pool to the connection. That pool name is merged into the hash with the name key.
This requires that the @configurations was initialized with a key that matches.
configurations = #<ActiveRecord::DatabaseConfigurations:0x00007fd9fdace3e0 @configurations=[ #<ActiveRecord::DatabaseConfigurations::HashConfig:0x00007fd9fdace250 @env_name="production", @spec_name="primary", @config={"database"=>"my_db"}> ]> Resolver.new(configurations).resolve_symbol_connection(:production, "primary") # => { "database" => "my_db" }