Documentation ¶
Index ¶
- func ContextTransfer(ctx, targetCtx context.Context) context.Context
- func Handle(ctx context.Context, rp interface{})
- func HandleError(rp interface{}, handlerName string, w http.ResponseWriter, r *http.Request)
- func HandleErrorNoStack(ctx context.Context, err error)
- func HandleRequest(handlerName string, w http.ResponseWriter, r *http.Request)
- func HandleWithCtx(ctx context.Context, handlerName string)
- func Handler() func(http.Handler) http.Handler
- func New(text string) error
- func WrapWithExtra(err error, extraInfo map[string]interface{}) error
- type PanicWrap
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContextTransfer ¶ added in v0.1.17
ContextTransfer copies error handling related information from one context to another.
func HandleError ¶
func HandleError(rp interface{}, handlerName string, w http.ResponseWriter, r *http.Request)
HandleError reports the passed error to sentry
func HandleErrorNoStack ¶ added in v0.1.29
func HandleRequest ¶
func HandleRequest(handlerName string, w http.ResponseWriter, r *http.Request)
HandleRequest should be called with defer to recover panics in request handlers
func HandleWithCtx ¶
HandleWithCtx should be called with defer to recover panics in goroutines
func WrapWithExtra ¶
WrapWithExtra adds extra data to an error before reporting to Sentry
Types ¶
Click to show internal directories.
Click to hide internal directories.