Sha256: 5cf57bdcc36fec0146bb681eff3d9f26f6423e13241988d3c63ec7f59aba8f7d
Contents?: true
Size: 724 Bytes
Versions: 1
Compression:
Stored size: 724 Bytes
Contents
require 'active_record' require 'fresh_connection/access_control' require 'fresh_connection/connection_manager' require 'fresh_connection/slave_connection_handler' module FreshConnection extend ActiveSupport::Autoload autoload :ConnectionManager autoload :SlaveConnectionHandler class << self attr_writer :connection_manager, :env def connection_manager @connection_manager || ConnectionManager end def env @env || defined?(Rails) && Rails.env end def rails_3? ActiveRecord::VERSION::MAJOR == 3 end def rails_4? ActiveRecord::VERSION::MAJOR == 4 end end end require 'fresh_connection/extend' require "fresh_connection/railtie" if defined?(Rails)
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
fresh_connection-0.3.0 | lib/fresh_connection.rb |