Module: GraphQL::Tracing::AppsignalTrace

Defined in:
lib/graphql/tracing/appsignal_trace.rb

Defined Under Namespace

Classes: AppsignalMonitor

Instance Method Summary collapse

Instance Method Details

#initialize(set_action_name: false, **rest) ⇒ Object

Parameters:

  • set_action_name (Boolean) (defaults to: false)

    If true, the GraphQL operation name will be used as the transaction name. This is not advised if you run more than one query per HTTP request, for example, with graphql-client or multiplexing. It can also be specified per-query with context[:set_appsignal_action_name].



17
18
19
20
21
# File 'lib/graphql/tracing/appsignal_trace.rb', line 17

def initialize(set_action_name: false, **rest)
  rest[:set_transaction_name] ||= set_action_name
  setup_appsignal_monitor(**rest)
  super
end