format

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2022 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExitOnErr

func ExitOnErr(logger logr.Logger, err error, msg string)

ExitOnErr logs the error and exit if error is not nil

func GetLogger

func GetLogger(v int) logr.Logger

GetLogger returns a stdr.Logger that implements the logr.Logger interface and sets the verbosity of the returned logger. set v to 0 for info level messages, 1 for debug messages and 2 for trace level message. any other verbosity level will default to 0.

func MemUsageToStdErr

func MemUsageToStdErr(logger logr.Logger)

MemUsageToStdErr logs the total PSI memory usage, and garbage collector calls

func ShowUsageAndExit

func ShowUsageAndExit(usage func(), exitcode int)

ShowUsageAndExit displays the usage message to stdout and exit

Types

This section is empty.

Jump to

Keyboard shortcuts

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