123456789_123456789_123456789_123456789_123456789_

Exception: ActiveRecord::ConnectionNotEstablished

Relationships & Source Files
Extension / Inclusion / Inheritance Descendants
Subclasses:
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
self, AdapterError, ActiveRecordError, StandardError
Instance Chain:
self, AdapterError, ActiveRecordError, StandardError
Inherits: ActiveRecord::AdapterError
Defined in: activerecord/lib/active_record/errors.rb

Overview

Raised when connection to the database could not been established (for example when {ActiveRecord::Base.connection=} is given a nil object).

Class Method Summary

Instance Attribute Summary

Instance Method Summary

Constructor Details

.new(message = nil, connection_pool: nil) ⇒ ConnectionNotEstablished

[ GitHub ]

  
# File 'activerecord/lib/active_record/errors.rb', line 72

def initialize(message = nil, connection_pool: nil)
  super(message, connection_pool: connection_pool)
end

Instance Method Details

#set_pool(connection_pool)

[ GitHub ]

  
# File 'activerecord/lib/active_record/errors.rb', line 76

def set_pool(connection_pool)
  unless @connection_pool
    @connection_pool = connection_pool
  end

  self
end