Documentation
¶
Index ¶
- func BasicAuth(users []BasicAuthUser) func(next http.Handler) http.Handler
- func CORS(cfg AccessControlConfig) func(next http.Handler) http.Handler
- func Recovery() func(http.Handler) http.Handler
- func RecoveryWithHandler(handler func(w http.ResponseWriter, r *http.Request, err interface{})) func(http.Handler) http.Handler
- func RecoveryWithLogger(logf func(format string, args ...interface{})) func(http.Handler) http.Handler
- func Timeout(timeout time.Duration) func(next http.Handler) http.Handler
- type AccessControlConfig
- type BasicAuthUser
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RecoveryWithHandler ¶
func RecoveryWithHandler(handler func(w http.ResponseWriter, r *http.Request, err interface{})) func(http.Handler) http.Handler
RecoveryWithHandler creates a middleware with a custom error handler
Types ¶
type AccessControlConfig ¶
type BasicAuthUser ¶
Click to show internal directories.
Click to hide internal directories.