Hi! We have a script taks with a exception flow , we have configured the timer with this:
If the script task delay more than 15 second it has to go in flow exception, but it doesnt
Any option??
Regards,Rebeca
Discussion posts and replies are publicly visible
I know this is an old thread, but we ran into same scenario. I had to wrap the script task in a subprocess to get this to work. Ideally, I would like to trigger the exception flow as soon as exception happens rather than skipping the node after preset time interval. Is there a way to achieve this.
Can you describe your scenario? What kind of expression are you executing in your script task? If you're calling an integration there is a better way to set this up, since the integration contains a timeout parameter: Integration Object.
It's legacy code where we have an expression with multiple integrations (read-only) being executed from that rule. We do have timeout set to 10 sec in integration rule. However, if the integration errors out due to any issue ( e.g., network connectivity issue), we would like to retry the entire expression
I think you're better off having a gateway after the script task that can check the results and decide whether to retry it. If you have a timeout in your integration, then the integration should never take more than 10 seconds (and the node should complete successfully), so then you can use the results to decide what to do next.
In general I'd recommend only using exceptions on nodes that are attended (e.g. Script Task, Sub-Process). Any other nodes it's usually better to have th node complete and then use logic in a gateway to determine what to do next.