log

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jul 9, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package log provides context-aware and structured logging capabilities.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithRequest

func WithRequest(ctx context.Context, req *http.Request) context.Context

Types

type Logger

type Logger interface {
	With(ctx context.Context, args ...interface{}) Logger
	Debug(args ...interface{})
	Info(args ...interface{})
	Error(args ...interface{})
	Debugf(format string, args ...interface{})
	Infof(format string, args ...interface{})
	Errorf(format string, args ...interface{})
}

func New

func New() Logger

func NewForTest

func NewForTest() (Logger, *observer.ObservedLogs)

func NewWithZap

func NewWithZap(l *zap.Logger) Logger

Jump to

Keyboard shortcuts

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