Sha256: 939c82fd9b286ea6c7e4fc7d44d8091a115327a8ac2de68112bb2dc57b22a126
Contents?: true
Size: 882 Bytes
Versions: 8
Compression:
Stored size: 882 Bytes
Contents
# This file is distributed under New Relic's license terms. # See https://github.com/newrelic/newrelic-ruby-agent/blob/main/LICENSE for complete details. # frozen_string_literal: true module NewRelic::Agent::Instrumentation module <%= @class_name %> def self.instrument! ::<%= @class_name %>.class_eval do include NewRelic::Agent::Instrumentation::<%= @class_name %> alias_method(:<%= @method.downcase %>_without_new_relic, :<%= @method.downcase %>) alias_method(:<%= @method.downcase %>, :<%= @method.downcase %>_with_new_relic) def <%= @method.downcase %><%= "(#{@args})" unless @args.empty? %> <%= @method.downcase %>_with_new_relic<%= "(#{@args})" unless @args.empty? %> do <%= @method.downcase %>_without_new_relic<%= "(#{@args})" unless @args.empty? %> end end end end end end
Version data entries
8 entries across 8 versions & 1 rubygems