Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • The History outcome is not determined as the order continues in the workflow. The History outcome will be determined from later workflow instructions.
  • Notifications can optionally be sent.
  • User Interventions Intervention is not applicable.


Code Block
titleExample for catching a job error by use of an empty Catch block
linenumberstrue
collapsetrue
Try
    job1
    job2
Catch
Catch-End
job3

...

  • The History outcome is specified to be failed as a Fail instruction is used.
  • Notifications can optionally be sent.
  • User Interventions Intervention is not applicable.


Code Block
titleExample for catching a job error with failed history outcome
linenumberstrue
collapsetrue
Try
    job1
    job2
Catch
    Fail (leave workflow)
Catch-End
job3

...

  • if any of job1 or job2 in the Try block raises an error then the order enters the Catch block.
  • In the Catch block the Fail instruction makes the order leave the workflow. The Fail instruction can be parameterized to either stop an order or to make an order leave the workflow.
    • If the above example is applied to child orders, for example in branches of Fork-Join and ForkList-Join instructions then the Fail instruction makes the child order leave the branch.
  • An order that enters the Catch block will not execute job3.

...

  • The History outcome is specified to be successful as a Try-Catch instruction is used to handle errors.
  • Notifications can optionally be sent.
  • User Interventions Intervention is not applicable.


Code Block
titleExample for catching a job error with successful history outcome
linenumberstrue
collapsetrue
Try
    job1
    job2
Catch
    Finish
Catch-End
job3

...

  • if any of job1 or job2 in the Try block raises an error then the order enters the Catch block.
  • In the Catch block the Finish instruction makes the order leave the workflow.
    • If the above example is applied to child orders, for example in branches of Fork-Join and ForkList-Join instructions then the Finish instruction makes the child order leave the branch.
  • An order that enters the Catch block will not execute job3.

...

  • The History outcome is not determined : as the order continues in the workflow. The History outcome will be determined from later workflow instructions.
  • Notifications can optionally be sent.
  • User Interventions Intervention is not applicable.


Code Block
titleExample for handling of job warnings
linenumberstrue
collapsetrue
job1 (return codes: 0=success, 1=warning, >1=error)
job2 (return codes: 0=success, 1=warning, >1=error)
job3 (return codes: 0=success, 1=warning, >1=error)

...

  • If any of job1, job2 or job3 completes with return code 1 this is considered a warning. Any other non-zero return codes are considered errors.
  • In case of job warnings the order continues with the next instruction in the workflow.
  • User Intervention is not applicable.

Feature Status:

Display feature availability
StartingFromRelease2.4.1

...

For earlier JS7 releases Notifications are not sent in case of job warnings.

Resources

...