instance method
establish_connection
Ruby on Rails 3.2.22.5
Since v2.2.3Signature
establish_connection(name, spec)
No documentation comment.
Parameters
-
namereq -
specreq
Source
# File activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb, line 374
def establish_connection(name, spec)
@connection_pools[spec] ||= ConnectionAdapters::ConnectionPool.new(spec)
@class_to_pool[name] = @connection_pools[spec]
end
Defined in activerecord/lib/active_record/connection_adapters/abstract/connection_pool.rb line 374
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::ConnectionHandler