Sha256: 9e5682a87a0212ac0d9339a3566aef744a424154bd8e53e8d2b69e65dc70261d
Contents?: true
Size: 759 Bytes
Versions: 12
Compression:
Stored size: 759 Bytes
Contents
# frozen_string_literal: true # Copyright The OpenTelemetry Authors # # SPDX-License-Identifier: Apache-2.0 module OpenTelemetry module Instrumentation module HttpClient module Patches # Module to prepend to HTTPClient::Session for instrumentation module Session def connect site = @proxy || @dest url = site.addr attributes = { 'http.url' => url }.merge!(OpenTelemetry::Common::HTTP::ClientContext.attributes) tracer.in_span('HTTP CONNECT', attributes: attributes) do super end end private def tracer HttpClient::Instrumentation.instance.tracer end end end end end end
Version data entries
12 entries across 12 versions & 1 rubygems