Documentation
¶
Index ¶
- func Ctx(ctx context.Context) *zerolog.Logger
- func DeferLogger(ctx context.Context, loss int64, err error, recove interface{}) *zerolog.Event
- func FormatTime(t time.Time, buf []byte) []byte
- func GetOutput() io.Writer
- func GinGet(ctx *gin.Context) *zerolog.Logger
- func GinWithLogid(ctx *gin.Context, logid int64) *zerolog.Logger
- func Init(ctx context.Context, conf config.Log) (err error)
- func Level(l string) (zerolog.Level, error)
- func Logid(ctx context.Context) (logid int64, ok bool)
- func New(writer ...io.Writer) *zerolog.Logger
- func WithLogid(ctx context.Context, logid int64) (context.Context, *zerolog.Logger)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeferLogger ¶
func FormatTime ¶
formatDate 自己实现的format函数比time.Format()性能要好
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.