Versions in this module Expand all Collapse all v3 deprecated v3.3.5 Sep 7, 2023 Changes in this version + const RequestIDKey + var DefaultLogger = RequestLogger(&DefaultLogFormatter{ ... }) + var LogEntryCtxKey = &contextKey + var URLFormatCtxKey = &contextKey + func AllowContentType(contentTypes ...string) func(next http.Handler) http.Handler + func CloseNotify(next http.Handler) http.Handler + func Compress(level int, types ...string) func(next http.Handler) http.Handler + func ContentCharset(charsets ...string) func(next http.Handler) http.Handler + func DefaultCompress(next http.Handler) http.Handler + func GetHead(next http.Handler) http.Handler + func GetReqID(ctx context.Context) string + func Heartbeat(endpoint string) func(http.Handler) http.Handler + func Logger(next http.Handler) http.Handler + func NextRequestID() uint64 + func NoCache(h http.Handler) http.Handler + func Profiler() http.Handler + func RealIP(h http.Handler) http.Handler + func Recoverer(next http.Handler) http.Handler + func RedirectSlashes(next http.Handler) http.Handler + func RequestID(next http.Handler) http.Handler + func RequestLogger(f LogFormatter) func(next http.Handler) http.Handler + func SetEncoder(encoding string, fn EncoderFunc) + func SetHeader(key, value string) func(next http.Handler) http.Handler + func StripSlashes(next http.Handler) http.Handler + func Throttle(limit int) func(http.Handler) http.Handler + func ThrottleBacklog(limit int, backlogLimit int, backlogTimeout time.Duration) func(http.Handler) http.Handler + func Timeout(timeout time.Duration) func(next http.Handler) http.Handler + func URLFormat(next http.Handler) http.Handler + func WithLogEntry(r *http.Request, entry LogEntry) *http.Request + func WithValue(key interface{}, val interface{}) func(next http.Handler) http.Handler + type DefaultLogFormatter struct + Logger LoggerInterface + NoColor bool + func (l *DefaultLogFormatter) NewLogEntry(r *http.Request) LogEntry + type EncoderFunc func(w http.ResponseWriter, level int) io.Writer + type LogEntry interface + Panic func(v interface{}, stack []byte) + Write func(status, bytes int, elapsed time.Duration) + func GetLogEntry(r *http.Request) LogEntry + type LogFormatter interface + NewLogEntry func(r *http.Request) LogEntry + type LoggerInterface interface + Print func(v ...interface{}) + type WrapResponseWriter interface + BytesWritten func() int + Status func() int + Tee func(io.Writer) + Unwrap func() http.ResponseWriter + func NewWrapResponseWriter(w http.ResponseWriter, protoMajor int) WrapResponseWriter Other modules containing this package github.com/go-chi/chi github.com/go-chi/chi/v2 github.com/go-chi/chi/v4 github.com/go-chi/chi/v5