Sha256: 517f9d45947111a6b421e15616870b324fc863d2e4dc2178a7fcfb55cc7bf87b
Contents?: true
Size: 647 Bytes
Versions: 2
Compression:
Stored size: 647 Bytes
Contents
require_relative '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
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ddtrace-1.10.1 | lib/datadog/tracing/analytics.rb |
ddtrace-1.10.0 | lib/datadog/tracing/analytics.rb |