noop

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 29, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package noop provides a no-operation tracer implementation for the tracing package. This package creates a minimal tracer provider that satisfies the tracing interface but doesn't collect or export any spans. It's useful for development environments, testing, or situations where tracing needs to be disabled without changing code structure.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Install

func Install(cfgs *configs.Configs) (*sdktrace.TracerProvider, error)

Install initializes and returns a minimal no-operation tracer provider. The provider is created with default settings and no exporters, meaning it will not collect or export any spans. This is useful when tracing overhead should be avoided but code that expects a tracer should still work.

The tracer provider is stored in the configs object for use throughout the application.

Parameters:

  • cfgs: Application configurations to store the tracer provider

Returns:

  • *sdktrace.TracerProvider: A minimal tracer provider with no exporters
  • error: Always nil for the noop implementation

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL