[#237] Improve request log
All checks were successful
/ DCO (pull_request) Successful in 46s
/ Builds (pull_request) Successful in 1m17s
/ Vulncheck (pull_request) Successful in 1m33s
/ OCI image (pull_request) Successful in 1m59s
/ Lint (pull_request) Successful in 2m33s
/ Tests (pull_request) Successful in 1m44s
/ Integration tests (pull_request) Successful in 7m5s

It's better to see original URI rather than decoded

Signed-off-by: Denis Kirillov <d.kirillov@yadro.com>
This commit is contained in:
Denis Kirillov 2025-04-29 16:33:03 +03:00
parent 96a22d98f2
commit b6b6474d0b

View file

@ -863,8 +863,7 @@ func (a *app) logger(h fasthttp.RequestHandler) fasthttp.RequestHandler {
log.Info(logs.Request, zap.String("remote", req.RemoteAddr().String()),
zap.ByteString("method", req.Method()),
zap.ByteString("path", req.Path()),
zap.ByteString("query", req.QueryArgs().QueryString()),
zap.ByteString("uri", req.RequestURI()),
logs.TagField(logs.TagDatapath))
h(req)
}