What are the common use cases for Try catch in journeys?
0
-
- Database operations: Actions that perform database queries or updates, especially where there might be a risk of query failure due to syntax errors, connection timeouts, or constraint violations.
- File operations: Actions that handle file uploads, downloads, reading from or writing to files where there could be issues like file not found, permission denied, or file in use.
- Data transformation: Complex data manipulation tasks such as parsing JSON, converting data formats (For example, XML to JSON, CSV to Excel), or applying transformations that might fail if the input data is not in the expected format.
- External service integrations: Any interactions with external services such as sending emails, SMS messages, or notifications where failures could occur due to service downtime or configuration errors.
- Dynamic content generation: Actions that involve generating content dynamically, such as creating PDF documents or rendering images based on user inputs, which may fail due to invalid input or rendering errors.
- Handling database downtime: Database If the target database is not ready (downtime or temporary locking of rows due to other queries), add a delay in the Catch block using a scheduler for a few minutes and retry the same insert operation on the target database. Users can auto-retry instead of re-running the transaction that failed due to runtime errors.
0
Please sign in to leave a comment.
Comments
1 comment