Sha256: 678fdf5d0775e648b0747e6883714ae23a92a8fea60238afc2ad8e3008bc9a22
Contents?: true
Size: 764 Bytes
Versions: 12
Compression:
Stored size: 764 Bytes
Contents
# typed: true require_relative '../analytics' module Datadog module Tracing module Contrib # Defines analytics behavior for integrations # @public_api module Analytics module_function # Checks whether analytics should be enabled. # `flag` is a truthy/falsey value that represents a setting on the integration. def enabled?(flag = nil) (Datadog.configuration.tracing.analytics.enabled && flag != false) || flag == true end def set_sample_rate(span, sample_rate) Tracing::Analytics.set_sample_rate(span, sample_rate) end def set_measured(span, value = true) Tracing::Analytics.set_measured(span, value) end end end end end
Version data entries
12 entries across 12 versions & 1 rubygems