lib/one_apm/transaction.rb in oneapm_rpm-1.3.2 vs lib/one_apm/transaction.rb in oneapm_rpm-1.3.3.rc1

- old
+ new

@@ -96,11 +96,11 @@ else name = @frozen_name trace_options = TRACE_OPTIONS_UNSCOPED end - trace_options = TRACE_IGNORE_OPTIONS if !ignore_frames.empty? && ignore_frames.include?(outermost_frame.name) + trace_options = TRACE_IGNORE_OPTIONS if ignore_frame?(outermost_frame.name) # These metrics are recorded here instead of in record_summary_metrics # in order to capture the exclusive time associated with the outer-most # TT node. if needs_middleware_summary_metrics?(name) @@ -217,10 +217,11 @@ agent.error_collector.notice_error(exception, options) end end def merge_metrics + return if ignore_frame?(best_name) agent.stats_engine.merge_transaction_metrics!(@metrics, best_name) end def instrumentation_state @instrumentation_state ||= {} @@ -293,9 +294,14 @@ if @exceptions[error] @exceptions[error].merge! options else @exceptions[error] = options end + end + + def ignore_frame? tx_name + return false if ignore_frames.empty? + ignore_frames.any?{|iframe| tx_name.to_s.match(/#{iframe}/)} end end end