log

package
v0.185.0 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2023 License: Apache-2.0 Imports: 1 Imported by: 237

Documentation

Overview

Package log provides a logging interface to send logs from plugins to Grafana server.

Index

Constants

This section is empty.

Variables

View Source
var DefaultLogger = New()

DefaultLogger is the default logger.

Functions

This section is empty.

Types

type Level added in v0.124.0

type Level int32
const (
	NoLevel Level = iota
	Trace
	Debug
	Info
	Warn
	Error
)

type Logger

type Logger interface {
	Debug(msg string, args ...interface{})
	Info(msg string, args ...interface{})
	Warn(msg string, args ...interface{})
	Error(msg string, args ...interface{})
	With(args ...interface{}) Logger
	Level() Level
}

Logger is the main Logger interface.

func New

func New() Logger

New creates a new logger.

func NewWithLevel added in v0.124.0

func NewWithLevel(level Level) Logger

NewWithLevel creates a new logger at the Level defined.

Jump to

Keyboard shortcuts

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