logger

package
v0.0.0-...-e939e73 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DynamicLogger

type DynamicLogger struct {
	*zap.Logger
	// contains filtered or unexported fields
}

DynamicLogger wraps zap.Logger with ability to switch levels at runtime

func NewDefaultLogger

func NewDefaultLogger() (*DynamicLogger, error)

NewDefaultLogger creates a default logger for initial startup logging

func NewLogger

func NewLogger(config configtypes.LogConfig) (*DynamicLogger, error)

NewLogger creates a new Zap logger with appropriate configuration

func NewLoggerWithStartupOverride

func NewLoggerWithStartupOverride(config configtypes.LogConfig) (*DynamicLogger, error)

NewLoggerWithStartupOverride creates a logger that starts at INFO level if configured level is higher, then can be switched to configured level using SwitchToConfiguredLevel()

func (*DynamicLogger) EnsureInfoLevelForShutdown

func (dl *DynamicLogger) EnsureInfoLevelForShutdown()

EnsureInfoLevelForShutdown ensures both console and file loggers are at INFO level to guarantee visibility of shutdown sequence logs

func (*DynamicLogger) SwitchToConfiguredLevel

func (dl *DynamicLogger) SwitchToConfiguredLevel()

SwitchToConfiguredLevel switches logger to the originally configured level

Jump to

Keyboard shortcuts

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