Module: Datadog::Core::ProcessDiscovery
- Defined in:
- lib/datadog/core/process_discovery.rb,
lib/datadog/core/process_discovery/tracer_memfd.rb,
ext/libdatadog_api/process_discovery.c
Overview
Class used to store tracer metadata in a native file descriptor.
Defined Under Namespace
Classes: TracerMemfd
Class Method Summary collapse
- ._native_close_tracer_memfd ⇒ Object
-
._native_store_tracer_metadata ⇒ Object
Class cannot be instantiated from Ruby.
- ._native_to_rb_int ⇒ Object
- .after_fork ⇒ Object
- .publish(settings) ⇒ Object
- .shutdown! ⇒ Object
Class Method Details
._native_close_tracer_memfd ⇒ Object
10 |
# File 'ext/libdatadog_api/process_discovery.c', line 10 static VALUE _native_close_tracer_memfd(DDTRACE_UNUSED VALUE _self, VALUE tracer_memfd, VALUE logger); |
._native_store_tracer_metadata ⇒ Object
Class cannot be instantiated from Ruby
8 |
# File 'ext/libdatadog_api/process_discovery.c', line 8 static VALUE (int argc, VALUE *argv, DDTRACE_UNUSED VALUE _self); |
._native_to_rb_int ⇒ Object
9 |
# File 'ext/libdatadog_api/process_discovery.c', line 9 static VALUE _native_to_rb_int(DDTRACE_UNUSED VALUE _self, VALUE tracer_memfd); |
.after_fork ⇒ Object
31 32 33 34 |
# File 'lib/datadog/core/process_discovery.rb', line 31 def after_fork # The runtime-id changes after a fork. We call publish to ensure that the runtime-id is updated. publish(Datadog.configuration) end |
.publish(settings) ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/datadog/core/process_discovery.rb', line 12 def publish(settings) if (libdatadog_api_failure = Datadog::Core::LIBDATADOG_API_FAILURE) Datadog.logger.debug { "Cannot enable process discovery: #{libdatadog_api_failure}" } return end = (settings) shutdown! @file_descriptor = (Datadog.logger, **) end |
.shutdown! ⇒ Object
24 25 26 27 28 29 |
# File 'lib/datadog/core/process_discovery.rb', line 24 def shutdown! if defined?(@file_descriptor) @file_descriptor&.shutdown!(Datadog.logger) @file_descriptor = nil end end |