Sha256: 95e89a577f0cbea708052eb84ca14d1c6fafd9fa112c4174a3c1fdb93faa20df
Contents?: true
Size: 891 Bytes
Versions: 7
Compression:
Stored size: 891 Bytes
Contents
# encoding: utf-8 require 'ting_yun/instrumentation/support/active_record_subscriber' TingYun::Support::LibraryDetection.defer do named :active_record_4 depends_on do !::TingYun::Agent.config[:disable_active_record] end depends_on do defined?(::ActiveRecord) && defined?(::ActiveRecord::Base) && defined?(::ActiveRecord::VERSION) && ::ActiveRecord::VERSION::MAJOR.to_i >= 4 end depends_on do !TingYun::Instrumentation::Rails::ActiveRecordSubscriber.subscribed? end executes do ::TingYun::Agent.logger.info 'Installing ActiveRecord 4 instrumentation' end executes do ActiveSupport::Notifications.subscribe('sql.active_record', TingYun::Instrumentation::Rails::ActiveRecordSubscriber.new) ::TingYun::Instrumentation::Support::ActiveRecordHelper.instrument_additional_methods end end
Version data entries
7 entries across 7 versions & 1 rubygems