qlog

package
v1.0.8 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2026 License: BSD-3-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetLogger

func SetLogger(logger Logger)

SetLogger sets the global logger.

Types

type Logger

type Logger interface {
	// Errorf logs a message at error level.
	Errorf(msg string, keysAndValues ...any)
	// Infof logs a message at info level.
	Infof(msg string, keysAndValues ...any)
}
var DefaultLogger Logger = PrintfLogger(log.New(os.Stdout, "go-queue: ", log.LstdFlags))

func PrintfLogger

func PrintfLogger(l interface{ Printf(string, ...interface{}) }) Logger

PrintfLogger wraps a Printf-based logger (such as the standard library "log") into an implementation of the Logger interface which logs errors only.

Jump to

Keyboard shortcuts

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