Sha256: 715af642de76d098f39ca7dfc65d6c44fba6ba4668f05cb05cfe41fd02e088d3

Contents?: true

Size: 775 Bytes

Versions: 4

Compression:

Stored size: 775 Bytes

Contents

# typed: true

require 'datadog/tracing'
require 'datadog/tracing/contrib/patcher'
require 'datadog/tracing/contrib/active_model_serializers/ext'
require 'datadog/tracing/contrib/active_model_serializers/events'

module Datadog
  module Tracing
    module Contrib
      module ActiveModelSerializers
        # Patcher enables patching of 'active_model_serializers' module.
        module Patcher
          include Contrib::Patcher

          module_function

          def target_version
            Integration.version
          end

          def patch
            Events.subscribe!
          end

          def get_option(option)
            Datadog.configuration.tracing[:active_model_serializers].get_option(option)
          end
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
ddtrace-1.2.0 lib/datadog/tracing/contrib/active_model_serializers/patcher.rb
ddtrace-1.1.0 lib/datadog/tracing/contrib/active_model_serializers/patcher.rb
ddtrace-1.0.0 lib/datadog/tracing/contrib/active_model_serializers/patcher.rb
ddtrace-1.0.0.beta2 lib/datadog/tracing/contrib/active_model_serializers/patcher.rb