log

package
v1.26.0 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2020 License: Apache-2.0, BSD-3-Clause, Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package log provides logging utilities for the tracer.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(fmt string, a ...interface{})

Debug prints the given message if the level is LevelDebug.

func Error

func Error(format string, a ...interface{})

Error reports an error. Errors get aggregated and logged periodically. The default is once per minute or once every DD_LOGGING_RATE number of seconds.

func Flush

func Flush()

Flush flushes and resets all aggregated errors to the logger.

func Info added in v1.26.0

func Info(fmt string, a ...interface{})

Info prints an informational message.

func SetLevel

func SetLevel(lvl Level)

SetLevel sets the given lvl for logging.

func UseLogger

func UseLogger(l ddtrace.Logger)

UseLogger sets l as the active logger.

func Warn

func Warn(fmt string, a ...interface{})

Warn prints a warning message.

Types

type Level

type Level int

Level specifies the logging level that the log package prints at.

const (
	// LevelDebug represents debug level messages.
	LevelDebug Level = iota
	// LevelWarn represents warning and errors.
	LevelWarn
)

Jump to

Keyboard shortcuts

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