mirror of
https://github.com/go-kratos/kratos.git
synced 2025-01-10 00:29:01 +02:00
21557b38f6
* add log context & valuer
265 B
265 B
Log
Usage
Structured logging
logger := log.NewLogger(os.Stdout)
logger = With(logger, "key", "value")
log := log.NewHelper("github.com/project/foo", logger)
// Levels
log.Info("hello")
log.Infof("hello %s", "kratos")
log.Infow("key", "value")