fix: DetailedLog format. (#4467)

This commit is contained in:
不插电 2024-12-21 11:48:27 +08:00 committed by GitHub
parent 8625864d43
commit f57874a51f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -160,7 +160,7 @@ func logDetails(r *http.Request, response *detailLoggedResponseWriter, timer *ut
r.Method, code, r.RemoteAddr, timex.ReprOfDuration(duration), dumpRequest(r)))
if duration > slowThreshold.Load() {
logger.Slowf("[HTTP] %s - %d - %s - slowcall(%s)\n=> %s\n", r.Method, code, r.RemoteAddr,
fmt.Sprintf("slowcall(%s)", timex.ReprOfDuration(duration)), dumpRequest(r))
timex.ReprOfDuration(duration), dumpRequest(r))
}
body := logs.Flush()