Ring utility functions.
Ring utility functions.
(wrap-report-exceptions handler
{:keys [preprocess-fn postprocess-fn error-fn]
:or {preprocess-fn identity
postprocess-fn (comp second list)
error-fn default-error}})
Wraps the given handler in error reporting.
Optionally takes three functions:
:preprocess-fn
, which is passed the request:postprocess-fn
, which is passed the request and the Sentry event:error-fn
, which is passed the request and the thrown exception and returns an appropriate Ring responseWraps the given handler in error reporting. Optionally takes three functions: * `:preprocess-fn`, which is passed the request * `:postprocess-fn`, which is passed the request and the Sentry event * `:error-fn`, which is passed the request and the thrown exception and returns an appropriate Ring response
(wrap-sentry-tracing handler)
(wrap-sentry-tracing handler
{:keys [preprocess-fn] :or {preprocess-fn identity}})
Wraps the given handler in tracing.
Optionally takes one function:
:preprocess-fn
, which is passed the requestWraps the given handler in tracing. Optionally takes one function: * `:preprocess-fn`, which is passed the request
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close