Sha256: e0456fd38cdcac4d87e6f70dfc86c0af7394a99e5f419927c3d683aed2ae5387

Contents?: true

Size: 546 Bytes

Versions: 18

Compression:

Stored size: 546 Bytes

Contents

# Extend the controller with extra behavior from web transactions
# This is just temporary until we switchover to WebTransaction from Controller.

NewRelic::MetricParser::Controller.class_eval do
  
  def initialize(name)
    super
    if %w[Sinatra Rack Task].include?(segment_1)
      self.extend NewRelic::MetricParser::WebTransaction.const_get(segment_1)
    end
  end
  
  # default to v2 Web Transactions tab
  def drilldown_url(metric_id)
    {:controller => '/v2/transactions', :action => 'index', :anchor => "id=#{metric_id}"}
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
newrelic_rpm-2.14.1.logging1 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.14.1 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4.rum6 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.14.0 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4.rum5 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.6.beta2 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.6.beta1 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4.rum4 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.5.beta4 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.5.beta3 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.5.beta2 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.5.beta1 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4.eum3 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4.eum2 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4.eum1 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.4 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.3 vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb
newrelic_rpm-2.13.3.beta vendor/gems/metric_parser-0.1.0.pre1/lib/new_relic/metric_parser/controller_ext.rb