http: Add response headers to access logs
This commit is contained in:
parent
16782d9988
commit
a19da07b72
1 changed files with 1 additions and 0 deletions
|
|
@ -121,6 +121,7 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
||||||
zap.Duration("latency", latency),
|
zap.Duration("latency", latency),
|
||||||
zap.Int("size", wrec.Size()),
|
zap.Int("size", wrec.Size()),
|
||||||
zap.Int("status", wrec.Status()),
|
zap.Int("status", wrec.Status()),
|
||||||
|
zap.Object("resp_headers", LoggableHTTPHeader(wrec.Header())),
|
||||||
)
|
)
|
||||||
}()
|
}()
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue