glogger

package module
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2021 License: MIT Imports: 7 Imported by: 0

README

MSLoggger

基于ZAP封装的日志库

Documentation

Index

Constants

View Source
const (
	RequestID  string = "requestId"
	PlatformID string = "platformId"
	UserFlag   string = "userFlag"
	Duration   string = "duration"
	Size       string = "size"
)

Variables

This section is empty.

Functions

func Debug

func Debug(msg string, fields ...zap.Field)

func Error

func Error(msg string, fields ...zap.Field)

func Info

func Info(msg string, fields ...zap.Field)

Types

type GLogger

type GLogger struct {
	// contains filtered or unexported fields
}

func CreateLog

func CreateLog() GLogger

func WithContext

func WithContext(ctx *context.Context) GLogger

func (GLogger) Debug

func (log GLogger) Debug(msg string, fields ...zap.Field)

func (GLogger) Error

func (log GLogger) Error(msg string, fields ...zap.Field)

func (GLogger) Errorf

func (log GLogger) Errorf(msg string, args ...interface{})

func (GLogger) Info

func (log GLogger) Info(msg string, fields ...zap.Field)

func (GLogger) Infof

func (log GLogger) Infof(msg string, args ...interface{})

func (GLogger) Warnf

func (log GLogger) Warnf(msg string, args ...interface{})

func (GLogger) With

func (log GLogger) With(fields ...zap.Field) GLogger

Directories

Path Synopsis
core

Jump to

Keyboard shortcuts

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