Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PanicHandler ¶
func PanicHandler(handler fasthttp.RequestHandler, onRecover PanicRecoveryHandler) fasthttp.RequestHandler
PanicHandler wraps original request handler with custom panic recovery logic (`PanicRecoveryHandler`)
func SimplePanicHandler ¶
func SimplePanicHandler(handler fasthttp.RequestHandler) fasthttp.RequestHandler
SimplePanicHandler covers the most simple case when FastHTTP server needs to return HTTP 500 on unhandled panics.
Types ¶
type PanicRecoveryHandler ¶
type PanicRecoveryHandler func(ctx *fasthttp.RequestCtx, recoverDetails interface{})
PanicRecoveryHandler is an extension of standard fasthttp.RequestHandler.
`recoverDetails` contains all the details from 'recover()' call.
Click to show internal directories.
Click to hide internal directories.