[#237] Improve request log
All checks were successful
/ Builds (push) Successful in 1m30s
/ Vulncheck (push) Successful in 1m27s
/ OCI image (push) Successful in 2m18s
/ Lint (push) Successful in 2m47s
/ Tests (push) Successful in 1m42s
/ Integration tests (push) Successful in 6m35s

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 committed by Alexey Vanin
parent d85d7f319f
commit 381fbf0921

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()), 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)
} }