logger

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package logger provides functionality related to logging.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetLogger added in v1.5.0

func GetLogger() *zap.SugaredLogger

GetLogger returns the global logger instance.

func InitLoggerInRootCmd

func InitLoggerInRootCmd(verbose, json bool, logName string)

InitLoggerInRootCmd inits the provided logger instance based on command's flags. This is meant to be run by the root command in PersistentPreRun step.

func MustInitLogger

func MustInitLogger(json bool, logName string) *zap.Logger

MustInitLogger initializes logger and panics in case of an error. // FIXME Test this.

func MustInitVerboseLogger

func MustInitVerboseLogger(json bool, logName string) *zap.Logger

MustInitVerboseLogger initializes a verbose logger and panics in case of an error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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