Sha256: 88babda018f90435235c25178bf195d3d175db183925dac0f1d6d47c43a41f91
Contents?: true
Size: 669 Bytes
Versions: 4
Compression:
Stored size: 669 Bytes
Contents
# typed: true require 'datadog/tracing/metadata/ext' module Datadog module Tracing # Defines analytics behavior module Analytics class << self def set_sample_rate(span_op, sample_rate) return if span_op.nil? || !sample_rate.is_a?(Numeric) span_op.set_metric(Metadata::Ext::Analytics::TAG_SAMPLE_RATE, sample_rate) end def set_measured(span_op, value = true) return if span_op.nil? value = value == true || value == 1 ? 1 : 0 # rubocop:disable Style/MultipleComparison span_op.set_metric(Metadata::Ext::Analytics::TAG_MEASURED, value) end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems