# encoding: utf-8 require 'one_apm/inst/rails4/action_controller_subscriber' LibraryDetection.defer do @name = :rails4_controller depends_on do defined?(::Rails) && ::Rails::VERSION::MAJOR.to_i >= 4 end depends_on do defined?(ActionController) && defined?(ActionController::Base) end executes do OneApm::Manager.logger.info "Installing Rails #{::Rails::VERSION::MAJOR} Controller instrumentation" end executes do class ActionController::Base include OneApm::Agent::Instrumentation::TransactionBase end OneApm::Agent::Instrumentation::ActionControllerSubscriber \ .subscribe(/^process_action.action_controller$/) end end