Method: OneApm::Collector::Commands::XraySession#initialize

Defined in:
lib/one_apm/collector/commands/xray_session.rb

#initialize(command_arguments) ⇒ XraySession

Returns a new instance of XraySession.



15
16
17
18
19
20
21
22
23
24
# File 'lib/one_apm/collector/commands/xray_session.rb', line 15

def initialize(command_arguments)
  @command_arguments     = command_arguments
  @id                    = command_arguments.fetch("x_ray_id", nil)
  @xray_session_name     = command_arguments.fetch("xray_session_name", "")
  @key_transaction_name  = command_arguments.fetch("key_transaction_name", "")
  @requested_trace_count = command_arguments.fetch("requested_trace_count", 100)
  @duration              = command_arguments.fetch("duration", 86400)
  @sample_period         = command_arguments.fetch("sample_period", 0.1)
  @run_profiler          = command_arguments.fetch("run_profiler", true)
end