[#237] Improve request log #237
1 changed files with 1 additions and 2 deletions
|
@ -863,8 +863,7 @@ func (a *app) logger(h fasthttp.RequestHandler) fasthttp.RequestHandler {
|
||||||
|
|
||||||
log.Info(logs.Request, zap.String("remote", req.RemoteAddr().String()),
|
log.Info(logs.Request, zap.String("remote", req.RemoteAddr().String()),
|
||||||
zap.ByteString("method", req.Method()),
|
zap.ByteString("method", req.Method()),
|
||||||
zap.ByteString("path", req.Path()),
|
zap.ByteString("uri", req.RequestURI()),
|
||||||
zap.ByteString("query", req.QueryArgs().QueryString()),
|
|
||||||
logs.TagField(logs.TagDatapath))
|
logs.TagField(logs.TagDatapath))
|
||||||
h(req)
|
h(req)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue