Documentation ¶
Index ¶
Constants ¶
View Source
const JSON = "application/json"
JSON is the MIME type that we process
Variables ¶
This section is empty.
Functions ¶
func LogMW ¶
func LogMW(handler http.Handler, logger logrus.FieldLogger) http.HandlerFunc
LogMW wraps a regular handler and replaces the writer with some logging middleware.
Types ¶
type LogWriter ¶
type LogWriter struct { http.ResponseWriter // contains filtered or unexported fields }
LogWriter proxies http.ResponseWriter and logs.
func (*LogWriter) WriteHeader ¶
WriteHeader proxies http.ResponseWriter.WriteHeader
Click to show internal directories.
Click to hide internal directories.