logrus

package
v0.0.2 Latest Latest
Warning

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

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

Documentation

Overview

Package logrus provides an adapter to the go-kit log.Logger interface.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewLogger

func NewLogger(callerDep int) logapi.Interface

NewLogger returns a Go kit log.Logger that sends log events to a logrus.Logger.

Types

type Logger

type Logger struct {
	logrus.Ext1FieldLogger

	LocalFile      string
	RotateInterval int
	MaxFileSize    float64
	// contains filtered or unexported fields
}

Logger implement

func (Logger) Level

func (l Logger) Level() logapi.Level

func (Logger) Log

func (l Logger) Log(level logapi.Level, args ...interface{})

LogF wrap level and field

func (Logger) LogFf

func (l Logger) LogFf(level logapi.Level, fields logapi.Fields, format string, args ...interface{})

LogF wrap level and field

func (Logger) Logf

func (l Logger) Logf(level logapi.Level, format string, args ...interface{})

Log wrap level and field

func (Logger) SetLevel

func (l Logger) SetLevel(lvl logapi.Level)

func (*Logger) SetLoggerOutputFileConfig

func (l *Logger) SetLoggerOutputFileConfig(conf logapi.LoggerOutputFileConf)

func (*Logger) SetLoggerOutputType

func (l *Logger) SetLoggerOutputType(outputType logapi.LoggerOutputType)

Jump to

Keyboard shortcuts

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