Sha256: 4530bd3f04a1b90e63ebe522795135b1629a6aa41353b2d1ec8d5df57d31f17c

Contents?: true

Size: 755 Bytes

Versions: 3

Compression:

Stored size: 755 Bytes

Contents

# frozen_string_literal: true
require 'active_support'

ActiveSupport.on_load(:active_record) do
  require 'fresh_connection/extend/ar_base'
  require 'fresh_connection/extend/ar_relation'
  require 'fresh_connection/extend/ar_relation_merger'
  require 'fresh_connection/extend/ar_statement_cache'
  require 'fresh_connection/extend/ar_abstract_adapter'

  ActiveRecord::Base.extend FreshConnection::Extend::ArBase
  ActiveRecord::Relation.prepend FreshConnection::Extend::ArRelation
  ActiveRecord::Relation::Merger.prepend FreshConnection::Extend::ArRelationMerger
  ActiveRecord::StatementCache.prepend FreshConnection::Extend::ArStatementCache
  ActiveRecord::ConnectionAdapters::AbstractAdapter.extend FreshConnection::Extend::ArAbstractAdapter
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
fresh_connection-3.0.0 lib/fresh_connection/extend.rb
fresh_connection-3.0.0.rc2 lib/fresh_connection/extend.rb
fresh_connection-3.0.0.rc1 lib/fresh_connection/extend.rb