TRY/CATCH¶
TRY/CATCH handles failures without aborting the whole transform. TRY is an expression, so it can be used in LET, CASE, or output templates.
When to use it¶
Use TRY/CATCH around risky lookups, parsing, or assertions so you can emit a safe fallback value.
Syntax¶
The identifier inCATCH(...) is bound to an error object with message and type fields.
Example¶
Retry logic¶
Use RETRY with TIMES and optional BACKOFF for transient failures.
Pitfalls¶
- Keep the
TRYbody small so errors are easy to interpret. - Prefer
ASSERTfor explicit failure conditions; useTRY/CATCHto keep the pipeline running. BACKOFFunits follow host runtime defaults (for example, ms).