Sha256: 1369f50d75485bee095ab47d3293f94d73adc75afea0ee4da7dc348a186a770c

Contents?: true

Size: 754 Bytes

Versions: 12

Compression:

Stored size: 754 Bytes

Contents

# This file is distributed under New Relic's license terms.
# See https://github.com/newrelic/newrelic-ruby-agent/blob/main/LICENSE for complete details.
# frozen_string_literal: true

require_relative 'httpx/chain'
require_relative 'httpx/instrumentation'
require_relative 'httpx/prepend'

DependencyDetection.defer do
  named :httpx

  depends_on do
    defined?(HTTPX) && Gem::Version.new(HTTPX::VERSION) >= Gem::Version.new('1.0.0')
  end

  executes do
    NewRelic::Agent.logger.info('Installing httpx instrumentation')
  end

  executes do
    if use_prepend?
      prepend_instrument HTTPX::Session, NewRelic::Agent::Instrumentation::HTTPX::Prepend
    else
      chain_instrument NewRelic::Agent::Instrumentation::HTTPX::Chain
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
newrelic_rpm-9.14.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.13.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.12.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.11.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.10.2 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.10.1 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.10.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.9.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.8.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.7.1 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.7.0 lib/new_relic/agent/instrumentation/httpx.rb
newrelic_rpm-9.6.0 lib/new_relic/agent/instrumentation/httpx.rb