Sha256: 403d3d7b8b16be9eebd4eec9a378d803fbb3fa91d144c82a64f9319f8edaf309

Contents?: true

Size: 762 Bytes

Versions: 4

Compression:

Stored size: 762 Bytes

Contents

# frozen_string_literal: true

# Copyright The OpenTelemetry Authors
#
# SPDX-License-Identifier: Apache-2.0

module OpenTelemetry
  class Context
    module Propagation
      # A no-op extractor implementation
      class NoopExtractor
        # Extract a context from the given carrier
        #
        # @param [Object] carrier The carrier to extract the context from
        # @param [Context] context The context to be upated with the extracted
        #   context
        # @param [optional Callable] getter An optional callable that takes a carrier and a key and
        #   and returns the value associated with the key
        # @return [Context]
        def extract(carrier, context, &getter)
          context
        end
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
opentelemetry-api-0.13.0 lib/opentelemetry/context/propagation/noop_extractor.rb
opentelemetry-api-0.12.1 lib/opentelemetry/context/propagation/noop_extractor.rb
opentelemetry-api-0.12.0 lib/opentelemetry/context/propagation/noop_extractor.rb
opentelemetry-api-0.11.0 lib/opentelemetry/context/propagation/noop_extractor.rb