Module: CloudSearchRails
- Defined in:
- lib/cloud_search_rails.rb,
lib/cloud_search_rails/index.rb,
lib/cloud_search_rails/search.rb,
lib/cloud_search_rails/railtie.rb,
lib/cloud_search_rails/connection.rb,
lib/cloud_search_rails/exceptions.rb
Defined Under Namespace
Modules: ActiveRecord, Connection, Index, Search Classes: MissingSearchDomain, Railtie
Class Method Summary collapse
-
.activate_active_record! ⇒ Object
activate for ActiveRecord.
- .connection(domain = "default") ⇒ Object
Class Method Details
.activate_active_record! ⇒ Object
activate for ActiveRecord
19 20 21 |
# File 'lib/cloud_search_rails.rb', line 19 def self.activate_active_record! ::ActiveRecord::Base.send(:extend, CloudSearchRails::ActiveRecord) end |
.connection(domain = "default") ⇒ Object
13 14 15 16 |
# File 'lib/cloud_search_rails.rb', line 13 def self.connection(domain = "default") @connections ||= {} @connections[domain] ||= AWSCloudSearch::CloudSearch.new(domain) end |