logging

package
v1.21.0 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package logging provides logging helpers.

Index

Constants

This section is empty.

Variables

View Source
var RecentEntries = NewCircularBuffer(1024)

RecentEntries implements zap logging entries interception and stores the last 1024 entries in circular buffer in memory.

Functions

func NewCircularBuffer added in v0.4.0

func NewCircularBuffer(size int64) *circularBuffer

NewCircularBuffer creates a circular buffer for log entries in memory.

func Setup

func Setup(level zapcore.Level, encoding, uuid string)

Setup initializes logging with a given level.

func SetupWithZapLogger added in v1.19.0

func SetupWithZapLogger(logger *zap.Logger)

SetupWithZapLogger initializes zap logging with a given logger and its level.

func WithHooks added in v1.21.0

func WithHooks(logger *zap.Logger) *zap.Logger

WithHooks returns a logger with recent entries hooks.

Types

This section is empty.

Jump to

Keyboard shortcuts

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