Sha256: b4f26a035c33fb5715d8261fe69818912fbffa80785cff1bda0cc7c2577ebe4b

Contents?: true

Size: 565 Bytes

Versions: 5

Compression:

Stored size: 565 Bytes

Contents

# encoding: utf-8

module OneApm
  class Transaction

    def summary_metrics
      if @frozen_name.start_with?(OA_WEB_TRANSACTION_PREFIX)
        [OA_WEB_SUMMARY_METRIC]
      else
        background_summary_metrics
      end
    end

    def background_summary_metrics
      segments = @frozen_name.split('/')
      if segments.size > 2
        ["OtherTransaction/#{segments[1]}/all", OA_OTHER_SUMMARY_METRIC]
      else
        []
      end
    end

    def needs_middleware_summary_metrics?(name)
      name.start_with?(OA_MIDDLEWARE_PREFIX)
    end

  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
oneapm_rpm-1.4.2 lib/one_apm/transaction/transaction_summary.rb
oneapm_rpm-1.4.1 lib/one_apm/transaction/transaction_summary.rb
oneapm_rpm-1.4.0 lib/one_apm/transaction/transaction_summary.rb
oneapm_rpm-1.3.7 lib/one_apm/transaction/transaction_summary.rb
oneapm_rpm-1.3.7.rc1 lib/one_apm/transaction/transaction_summary.rb