logger

package
v0.9.13 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2024 License: MIT Imports: 10 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

Functions

func DebugWithFields

func DebugWithFields(fields logrus.Fields, args ...interface{})

func Errorf added in v0.9.12

func Errorf(format string, args ...interface{})

func Fatal

func Fatal(args ...interface{})

func Fatalf

func Fatalf(format string, args ...interface{})

func HandlerLog

func HandlerLog(LogToFile bool, LogFilePath string, LogFileName string) gin.HandlerFunc

HandlerLog 默认log

func Info

func Info(args ...interface{})

func Infof

func Infof(format string, args ...interface{})

func LoggerToStdout

func LoggerToStdout() gin.HandlerFunc

Types

type MyFormatter

type MyFormatter struct {
	FullTimestamp   bool
	TimestampFormat string // 使用完整时间戳
}

func (*MyFormatter) Format

func (m *MyFormatter) Format(entry *logrus.Entry) ([]byte, error)

Jump to

Keyboard shortcuts

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