mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-08-18 13:17:08 +00:00
admin: don't log normal 2xx/3xx HTTP requests (incl. 304 cache hits)
This commit is contained in:
@@ -565,7 +565,8 @@ func loggingMiddleware(next http.Handler) http.Handler {
|
||||
if status == 0 {
|
||||
status = http.StatusOK
|
||||
}
|
||||
if status >= 200 && status < 300 {
|
||||
// Only log errors; 2xx/3xx (including 304 Not Modified cache hits) are normal.
|
||||
if status < 400 {
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user