Sha256: fc8feadcdcaac74af7a329ad8dd6a3657d81b9c91ac6da88a6d8f5b76fb4e825

Contents?: true

Size: 673 Bytes

Versions: 1

Compression:

Stored size: 673 Bytes

Contents

# frozen_string_literal: true

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

module OpenTelemetry
  module Logs
    # No-op implementation of a logger provider.
    class LoggerProvider
      NOOP_LOGGER = OpenTelemetry::Logs::Logger.new
      private_constant :NOOP_LOGGER

      # Returns an {OpenTelemetry::Logs::Logger} instance.
      #
      # @param [optional String] name Instrumentation package name
      # @param [optional String] version Instrumentation package version
      #
      # @return [OpenTelemetry::Logs::Logger]
      def logger(name = nil, version = nil)
        @logger ||= NOOP_LOGGER
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
opentelemetry-logs-api-0.1.0 lib/opentelemetry/logs/logger_provider.rb