Classify exceptions into BND-xxx error codes. Pure functions — catalog data loaded once at namespace init via boundary.devtools.error-codes.
Classification strategy (ordered, first match wins):
Classify exceptions into BND-xxx error codes. Pure functions — catalog data loaded once at namespace init via boundary.devtools.error-codes. Classification strategy (ordered, first match wins): 1. ex-data with :boundary/error-code — direct BND code 2. ex-data pattern matching — infer from :type, :schema, :malli/error 3. Message pattern — regex on .getMessage() 4. Exception type — SQLException, ConnectException, etc. 5. Unclassified — nil code
(classify exception)Classify an exception into a BND-xxx error code.
Walks the cause chain: if the outermost exception has :boundary/error-code in ex-data (strategy 1), that takes precedence. Otherwise, classifies the root cause.
Returns a map with :code, :category, :exception, :data, :source or a map with :code nil for unclassified errors.
Classify an exception into a BND-xxx error code. Walks the cause chain: if the outermost exception has :boundary/error-code in ex-data (strategy 1), that takes precedence. Otherwise, classifies the root cause. Returns a map with :code, :category, :exception, :data, :source or a map with :code nil for unclassified errors.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |