Class: OrangeTap::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/orange_tap/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# File 'lib/orange_tap/config.rb', line 9

def initialize
  @output_dir = File.join(Dir.tmpdir, "orange_tap")
  @service_name = "orange_tap"
  @otel_converter = OrangeTap::OtelConverter
  # Opt-in "trace everything" mode. When true, a session installs a single
  # global :call/:return TracePoint that records every non-builtin Ruby
  # method call in the process, instead of the per-method registry hooks.
  # Built-ins are excluded by definition path (core internals + stdlib);
  # gems ARE traced, and C methods are always excluded (:call never fires
  # for them). This fires on every Ruby call process-wide, so it is heavy;
  # see BuiltinFilter and README. It supersedes explicit trace_method
  # registration when enabled.
  @trace_all_app_methods = false
  # Opt-in flag for tracing C-implemented methods. When false (default),
  # registering a C method raises UntraceableMethodError, as before. When
  # true, C methods are traced via a single global :c_call/:c_return
  # TracePoint per session, filtered by [owner, name] inside the hook.
  # This trades away the "zero overhead for unregistered methods"
  # guarantee for every C call in the process. See TODO-c-support.md.
  @trace_c_methods = false
end

Instance Attribute Details

#otel_converterObject

Returns the value of attribute otel_converter.



7
8
9
# File 'lib/orange_tap/config.rb', line 7

def otel_converter
  @otel_converter
end

#output_dirObject

Returns the value of attribute output_dir.



7
8
9
# File 'lib/orange_tap/config.rb', line 7

def output_dir
  @output_dir
end

#service_nameObject

Returns the value of attribute service_name.



7
8
9
# File 'lib/orange_tap/config.rb', line 7

def service_name
  @service_name
end

#trace_all_app_methodsObject

Returns the value of attribute trace_all_app_methods.



7
8
9
# File 'lib/orange_tap/config.rb', line 7

def trace_all_app_methods
  @trace_all_app_methods
end

#trace_c_methodsObject

Returns the value of attribute trace_c_methods.



7
8
9
# File 'lib/orange_tap/config.rb', line 7

def trace_c_methods
  @trace_c_methods
end