http: Add response headers to access logs

This commit is contained in:
Matthew Holt 2019-11-11 14:02:01 -07:00
parent 16782d9988
commit a19da07b72
No known key found for this signature in database
GPG Key ID: 2A349DD577D586A5

View File

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