Liking cljdoc? Tell your friends :D

clojure-commons.exception


as-de-exception-handlerclj

(as-de-exception-handler error-handler error-code)

Wraps a compojure-api exception handler function and performs the following tasks;

  • creates an exception map from the wrapped function's response
  • json encodes the exception map into the response body
  • adds json headers to response map

This function expects the error-handler to return a ring response with a ':errors' subkey in the response ':body'

Wraps a compojure-api exception handler function and performs
the following tasks;
  - creates an exception map from the wrapped function's response
  - json encodes the exception map into the response body
  - adds json headers to response map

This function expects the error-handler to return a ring response with
a ':errors' subkey in the response ':body'
raw docstring

authentication-not-found-handlerclj


bad-query-params-handlerclj


bad-request-field-handlerclj


bad-request-handlerclj


default-error-handlerclj

(default-error-handler response-fn error-code & [header-map])

Produces an error handler which generates exceptions with the given error-code and HTTP response function.

Produces an error handler which generates exceptions with the
given error-code and HTTP response function.
raw docstring

exception-handlersclj


failed-dependency-handlerclj


forbidden-handlerclj


handle-request-validation-errorsclj


handle-response-validation-errorsclj


illegal-argument-handlerclj


internal-system-error-handlerclj


invalid-cfg-handlerclj


invalid-json-handlerclj


item-exists-handlerclj


missing-query-params-handlerclj


missing-request-field-handlerclj


not-a-user-handlerclj


not-authorized-handlerclj


not-found-handlerclj


not-owner-handlerclj


not-unique-handlerclj


not-writeable-handlerclj


request-failed-handlerclj


temporary-redirect-handlerclj

(temporary-redirect-handler error error-type request)

Specialized exception handler for 302 responses. This could not be accomplished with the default exception handler because best practices for 302 responses is an empty response body.

Specialized exception handler for 302 responses. This could not be accomplished with the default
exception handler because best practices for 302 responses is an empty response body.
raw docstring

unavailable-handlerclj


unchecked-handlerclj

(unchecked-handler error error-type request)

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close