<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.appian.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/discussions/f/process/11643/how-to-handle-the-exception-of-a-node-in-process-and-define-a-different-flow-if-exception-occurs</link><description>Hi, 
 My requirement is I need to handle the exception (Technical) which occurs in any node in a process and once exception occurs I need to follow a different flow to inform the end user about the exception occurred and complete the process. All the</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/79158?ContentTypeID=1</link><pubDate>Tue, 26 Jan 2021 21:25:10 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c6e476d5-8365-463d-9f7d-863f0bece356</guid><dc:creator>karthip0001</dc:creator><description>&lt;p&gt;Correction. &amp;nbsp;OnError also worked when there was an identity number generation issue.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/67238?ContentTypeID=1</link><pubDate>Wed, 12 Jun 2019 01:33:11 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:fae18c98-bf08-435c-accd-e33d41785756</guid><dc:creator>karthip0001</dc:creator><description>&lt;p&gt;Hi, onError only works if the process fails to start.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51503?ContentTypeID=1</link><pubDate>Tue, 09 Jan 2018 12:37:52 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:bd56f222-a7b3-4dfd-b080-5d8b52890c76</guid><dc:creator>rp_balaji</dc:creator><description>Hi aloks176, &lt;br /&gt;
&lt;br /&gt;
Thanks for your detailed explanation. In my case it is not Appian user input task which will gets submitted to trigger a process, the UI which the user uses is a external HTML application and Appian process is triggered through WebAPI. So in this case I don have any user input task used in the process flow and it is only nodes which are related to DB and integration objects, in here if any node fails i need to terminate the process and send back the error response as an output of the process. In here I have an option in webapi that OnError attribute of startprocess smart service can be used to inform the user if there is any exception. But out of curiosity and knowledge purpose I would like to know what is an ideal way of defining a exception flow in the process as per the above requirement. As you said using a timer will be a set back as the system will have lot of process in memory in waiting state and that is a performance overhead.&lt;br /&gt;
&lt;br /&gt;
And in your response, in 3rd stanza you have mentioned to create a task report and with the time comparison logic you have asked to terminate the processes using a subprocess. So in here the sub process u r talking about is a individual process which will run as a batch and clear the processes or this subprocess needs to be called inside the main transactional process.   &lt;br /&gt;
&lt;br /&gt;
May I know the function or smart service name which can be used to get the processes which are failed due to exception for a particular process model.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Regards,&lt;br /&gt;
Balaji.R&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51485?ContentTypeID=1</link><pubDate>Tue, 09 Jan 2018 10:46:28 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:e4de9b26-1af8-4fd6-aff1-acf4fd1e3e87</guid><dc:creator>aloks0189</dc:creator><description>&lt;p&gt;Hi&amp;nbsp;&lt;a href="/members/balajir0001"&gt;rp_balaji&lt;/a&gt;&amp;nbsp;i agree, correct me if i am wrong, when you talk about Transaction, definitely you will be allowing standard amount of time for the process to complete it&amp;#39;s processing, hence anyhow if you hold the process for that long amount of time, will cause you activity chaining break, and will assign an another task to the end user, hence user won&amp;#39;t be informed through the interface, instead he need to pickup an another task else you need to send an email notification.&lt;br /&gt; &lt;br /&gt; Also when you talk about transaction, you must be very careful about performance, which you need to sacrifice if you want to go for timers. Let&amp;#39;s say, there are 10,000 instances for your process in production, which means there are 10,000 active timers which will cause you lot of performance issues.&lt;br /&gt; &lt;br /&gt; So, instead of this the better way could be, create a task report for this Transactional Process (which only contains Transaction logic excluding User Input Task, and will be triggered only when User Input Task gets submitted) and capture it&amp;#39;s start time then compare the time duration between it&amp;#39;s start time and now() if it&amp;#39;s more than your defined business transaction rules then simply get the process instance it and terminate it using subrocess&lt;br /&gt; &lt;br /&gt; Also, this an be automated using one Cleanup process, which will collect all this data, and if there are any process instance with matching criteria, simply terminate them, and before termination, get the initiator of that process and trigger an email post termination of this instance.&lt;br /&gt; &lt;br /&gt; Also, you can query for those processes whose status is Paused by Exception with in the context of this Transactional Process model, which will return you those processes which have failed during it&amp;#39;s execution.&lt;br /&gt; &lt;br /&gt; I believe this could be the better approach, however it&amp;#39;s your call, because you will have more understanding about your business requirement. This is just an another approach which can be feasible for your scenario.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51482?ContentTypeID=1</link><pubDate>Tue, 09 Jan 2018 10:29:06 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:797c72b2-5d51-4c28-8009-04e57ead8194</guid><dc:creator>rp_balaji</dc:creator><description>Hi aloks176,&lt;br /&gt;
&lt;br /&gt;
Thanks for your response, in our case the end user needs to be informed about the status of the transaction as the process is a Synchronous process and not asynchronous. The point which you have mentioned &amp;quot;end-user should never be informed about errors&amp;quot; will be true if the process is asynchronous and in that case the end user will submit the task/form and the administrator will correct the process if there is an error in the node.&lt;br /&gt;
&lt;br /&gt;
But in my present scenario, as I need to handle the exception case I need to wrap the node in a subprocess and define the flag variable and timer to handle the exception and follow a exception path and complete the process and inform the user that there is an error in the transaction.&lt;br /&gt;
&lt;br /&gt;
If in case if you feel the above case can be done in a better way without using timer event, let me know so that ill try it out&lt;br /&gt;
&lt;br /&gt;
Regards,&lt;br /&gt;
Balaji.R&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51474?ContentTypeID=1</link><pubDate>Tue, 09 Jan 2018 09:20:58 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d9685cd2-5c13-4c34-ba2b-41d45a0ce15f</guid><dc:creator>aloks0189</dc:creator><description>&lt;p&gt;Hi @rpbalaji2006 as per my understanding, if you are more. Concern about performance, then do not use timer because it runs in background which degrades the application and server performance.&lt;/p&gt;
&lt;p&gt;Now coming to your query, first of all, end-user should never be informed about errors, because it&amp;#39;s the responsibility of administrators to deal with these errors and because they are configured under alerts tab hence they will be reported by Appian and also they will have e access to designer to check the respective alerts.&lt;/p&gt;
&lt;p&gt;You should never complete the process in case if node breaks, because this will cause you unexpected response / behaviour.&lt;/p&gt;
&lt;p&gt;For example, you next task is completely depending on previous process response, and now because you have timer configured so it will trigger the next process, now to handle that, you need to define a gateway which checks for a variable if it&amp;#39;s null then terminate the process, but process should not be configured in that way, because let&amp;#39;s say, your task got broken, and if process didn&amp;#39;t terminate then admin team can inspect and fix the issue by adding the patch and will restart from that node.&lt;/p&gt;
&lt;p&gt;Timers are best for the use case when you want to configure some schedulers in your application.&lt;/p&gt;
&lt;p&gt;Hope it will be helpful to you.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51457?ContentTypeID=1</link><pubDate>Tue, 09 Jan 2018 04:57:19 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:65e28a14-2dac-4678-ba5e-a312c19b1243</guid><dc:creator>rp_balaji</dc:creator><description>Hi ravir93,&lt;br /&gt;
&lt;br /&gt;
Thanks for your response, ill try the same as you suggested.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51423?ContentTypeID=1</link><pubDate>Mon, 08 Jan 2018 11:36:31 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d5e08c50-ec94-48f2-bbdd-22d7abfbdf22</guid><dc:creator>Ravi Roshan</dc:creator><description>&lt;p&gt;First of all set the flag at the End of the sub process, so in case your flow breaks in between your flag will be blank otherwise it will have true. You need to set the timer on the sub process setup as per your requirement (for eg., say 1 minute). Please see the attachments.&lt;/p&gt;
&lt;p&gt;&lt;a href="/cfs-file/__key/communityserver-discussions-components-files/14/Img-1.PNG"&gt;&lt;img src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/14/Img-1.PNG" alt=" " /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="/cfs-file/__key/communityserver-discussions-components-files/14/Img2.PNG"&gt;&lt;img src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/14/Img2.PNG" alt=" " /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Let me know if this helps..&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51422?ContentTypeID=1</link><pubDate>Mon, 08 Jan 2018 10:53:56 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:41ef8243-48eb-4c10-be09-cfc8305effb3</guid><dc:creator>rp_balaji</dc:creator><description>Hi ravir93,&lt;br /&gt;
&lt;br /&gt;
I have wrapped the exception case node in a subprocess and called it in the parent process as a synchronous process and using a flag variable to update if the node is success, as the node breaks due to exception the parent process also is not moving further after the subprocess execution.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51410?ContentTypeID=1</link><pubDate>Mon, 08 Jan 2018 07:30:37 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:f0468d09-f618-475c-8fca-f52bef9fc5bd</guid><dc:creator>Ravi Roshan</dc:creator><description>No, as the process breaks, there will not be any output for the variable configured to that node. In case if you want to know that this sub process execute successfully or not, you can make use of flag variable.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51409?ContentTypeID=1</link><pubDate>Mon, 08 Jan 2018 07:11:33 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c2b800fa-72cb-4aac-abbe-5ae959236b43</guid><dc:creator>rp_balaji</dc:creator><description>Hi Harsha,&lt;br /&gt;
Thanks for your response, I think this will work but I have a question here as the process flow breaks whenever there is a exception in the node, will the subprocess returns the result after the timer event?&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51408?ContentTypeID=1</link><pubDate>Mon, 08 Jan 2018 07:09:27 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:2c02977a-1db6-42aa-a3aa-0b3fdc6e45f2</guid><dc:creator>rp_balaji</dc:creator><description>Hi ravir93,&lt;br /&gt;
Thanks for your response, as you told coding error and data exception we are already handling but I need to know if there is a way to handle the service errors in the process and proceed further and take the exception path in the process flow.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51316?ContentTypeID=1</link><pubDate>Wed, 03 Jan 2018 09:34:15 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:764cd1e6-eb60-49a4-9eb3-b81696504b6e</guid><dc:creator>Harsha Sharma</dc:creator><description>One approach is to wrap the node inside a subprocess and have an exception timer on the subprocess inside parent process. When the node fails inside the sub process it will wait till the timer event then can route to error flow as you call it.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51308?ContentTypeID=1</link><pubDate>Wed, 03 Jan 2018 07:51:42 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d1476fe0-bc12-4660-8f06-eca6135f1357</guid><dc:creator>Ravi Roshan</dc:creator><description>It depends what is the configuration on the node. Exception can be of many form, if it is coding error we cannot handle this apart form solving the issue, apart from this there can be null handle scenario, may be data issue with the service call. For this kind of issue we can handle it.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to handle the exception of a node in process and define a different flow if exception occurs?</title><link>https://community.appian.com/thread/51269?ContentTypeID=1</link><pubDate>Tue, 02 Jan 2018 13:18:38 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d3c89566-29fa-4295-a701-00154e38bd5b</guid><dc:creator>bhupinders</dc:creator><description>I don&amp;#39;t think that&amp;#39;s possible. There is no way to handle exceptions and capture alerts in Appian.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>