Module: NewRelic::Agent::Instrumentation::Rails3::ActionController
- Defined in:
- lib/new_relic/agent/instrumentation/rails3/action_controller.rb
Constant Summary collapse
Instance Method Summary collapse
-
#newrelic_metric_path(action_name_override = nil) ⇒ Object
determine the path that is used in the metric name for the called controller action.
-
#process_action(*args) ⇒ Object
THREAD_LOCAL_ACCESS.
Instance Method Details
#newrelic_metric_path(action_name_override = nil) ⇒ Object
determine the path that is used in the metric name for the called controller action
16 17 18 19 20 21 22 23 |
# File 'lib/new_relic/agent/instrumentation/rails3/action_controller.rb', line 16 def newrelic_metric_path(action_name_override = nil) action_part = action_name_override || action_name if action_name_override || self.class.action_methods.include?(action_part) "#{self.class.controller_path}/#{action_part}" else "#{self.class.controller_path}/(other)" end end |
#process_action(*args) ⇒ Object
THREAD_LOCAL_ACCESS
25 26 27 28 29 30 31 32 33 34 35 36 |
# File 'lib/new_relic/agent/instrumentation/rails3/action_controller.rb', line 25 def process_action(*args) # THREAD_LOCAL_ACCESS NewRelic::Agent.record_instrumentation_invocation(INSTRUMENTATION_NAME) munged_params = NewRelic::Agent::ParameterFiltering.filter_rails_request_parameters(request.filtered_parameters) perform_action_with_newrelic_trace(:category => :controller, :name => self.action_name, :path => newrelic_metric_path, :params => munged_params, :class_name => self.class.name) do super end end |