class GraphQL::Tracing::ScoutTracing

Constants

INSTRUMENT_OPTS

Public Class Methods

new(options = {}) click to toggle source
Calls superclass method GraphQL::Tracing::PlatformTracing::new
# File lib/graphql/tracing/scout_tracing.rb, line 19
def initialize(options = {})
  self.class.include ScoutApm::Tracer
  super(options)
end

Public Instance Methods

platform_field_key(type, field) click to toggle source
# File lib/graphql/tracing/scout_tracing.rb, line 30
def platform_field_key(type, field)
  "#{type.name}.#{field.name}"
end
platform_trace(platform_key, key, data) { || ... } click to toggle source
# File lib/graphql/tracing/scout_tracing.rb, line 24
def platform_trace(platform_key, key, data)
  self.class.instrument("GraphQL", platform_key, INSTRUMENT_OPTS) do
    yield
  end
end