You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

The JS7 - Try / Catch Instruction is used for the error handling in a workflow. If any job runs in the try block and failed due to any reason the catch block will execute otherwise it will skip the catch block. If the catch block will also fail then the order will be considered as failed. The folder 04_ErrorHandling contains the example for the try-catch. The four workflows are available with the different use cases for the try-catch:

The jdFail workflow will execute and fail due to the fail operation is used in the workflow. Even if all the jobs will execute successfully and the fail object is used at the end of the workflow the order will fail and complete the workflow.

To execute all the workflow in the folder 04_ErrorHandling please follow the below steps:

  1. Click on the folder 04_ErrorHandling from the and expand any of the workflows. Here I am using jdFail workflow.




  2. To add the order in the workflow. Click on the action menu of the workflow and click on Add order button from the drop-down menu.




  3. On clicking the Add Order. A popup window will appear. 
  4. You can add the Order ID or leave the Order Id value blank it will take the default Order Id to process the Order. Click on Submit button to add the Order



  5. To check the status of the Order click on the Workflow name with this new Order history panel will appear. 



  6. From the Order history panel, you can see the Order is successful and finished. Click on the Order ID to open the detail logs of execution.



  7. A log window will open and the order log will be displayed. The order log contains log output from all jobs executed by the order. 
  8. You can download the log file by clicking the Download button from the upper right corner of the log window. Also, you can expand and collapse the individual job output using the arrow button from the left corner of the log window.



  • No labels