Sha256: 0e8b48ff7c04f9b4dbf01083bfbd492c3b13cd9e0d371db60867268f4fa21ee8
Contents?: true
Size: 456 Bytes
Versions: 7
Compression:
Stored size: 456 Bytes
Contents
module GovukOpenTelemetry def self.should_configure? ENV["ENABLE_OPEN_TELEMETRY"] == "true" end def self.configure(service_name) return unless should_configure? require "opentelemetry/sdk" require "opentelemetry/exporter/otlp" require "opentelemetry/instrumentation/all" OpenTelemetry::SDK.configure do |config| config.service_name = service_name config.use_all # enables all instrumentation! end end end
Version data entries
7 entries across 7 versions & 1 rubygems