Sha256: adf47ef02846af38f3aa6eccdfe9f7617f4051c184396655dbf034b1cf318076

Contents?: true

Size: 552 Bytes

Versions: 5

Compression:

Stored size: 552 Bytes

Contents

# typed: false
require 'ddtrace/contrib/patcher'

module Datadog
  module Contrib
    module Excon
      # Patcher enables patching of 'excon' module.
      module Patcher
        include Contrib::Patcher

        module_function

        def target_version
          Integration.version
        end

        def patch
          require 'ddtrace/contrib/excon/middleware'
          add_middleware
        end

        def add_middleware
          ::Excon.defaults[:middlewares] = Middleware.around_default_stack
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
ddtrace-0.54.2 lib/ddtrace/contrib/excon/patcher.rb
ddtrace-0.54.1 lib/ddtrace/contrib/excon/patcher.rb
ddtrace-0.54.0 lib/ddtrace/contrib/excon/patcher.rb
ddtrace-0.53.0 lib/ddtrace/contrib/excon/patcher.rb
ddtrace-0.52.0 lib/ddtrace/contrib/excon/patcher.rb