Sha256: 06c8bda22726e5909cb9ab203832c2eb13500d983b888741677411c9af328313

Contents?: true

Size: 1.07 KB

Versions: 7

Compression:

Stored size: 1.07 KB

Contents

# Defining a test controller class with a superclass, used to 
# verify correct attribute inheritence
class NewRelic::Agent::SuperclassController <  ActionController::Base
  def base_action
    render :text => 'none'
  end
end
# This is a controller class used in testing controller instrumentation
class NewRelic::Agent::AgentTestController < NewRelic::Agent::SuperclassController
  filter_parameter_logging :social_security_number

  def rescue_action(e) raise e end

  ActionController::Routing::Routes.draw do | map |
    map.connect ':controller/:action.:format'
  end
  
  def index
    render :text => params.inspect
  end
  def _filter_parameters(params)
    filter_parameters params
  end
  def action_to_render
    render :text => params.inspect
  end
  def action_to_ignore
    render :text => 'unmeasured'
  end
  def action_to_ignore_apdex
    render :text => 'unmeasured'
  end
  def entry_action
    perform_action_with_newrelic_trace('internal_action') do
      internal_action
    end    
  end
  private
  def internal_action
    render :text => 'internal action'
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
newrelic_rpm-2.9.9 test/new_relic/agent/agent_test_controller.rb
newrelic_rpm-2.9.8 test/new_relic/agent/agent_test_controller.rb
newrelic_rpm-2.9.6 test/new_relic/agent/agent_test_controller.rb
newrelic_rpm-2.9.5 test/new_relic/agent/agent_test_controller.rb
newrelic_rpm-2.9.2 test/new_relic/agent/agent_test_controller.rb
newrelic_rpm-2.9.3 test/new_relic/agent/agent_test_controller.rb
newrelic_rpm-2.9.4 test/new_relic/agent/agent_test_controller.rb