If a connection issue occurs, Terminal Session is killed and wrokflow crashes.
Use Retry Scope activity to reestablish connection (there are two variants, simple, that retries on all Exceptions and and ehanced version that exempts the Business Logic Exceptions (that are not caused by connectivity issues so there would be no point retrying on them)
There are two sample workflows included: - Simplified Session Recovery (that retries connection on all Exceptions, via System.Exception) - Enhanced Session Recovery (that exempts core.uipath.BusinessRuleException from the retry scope, on the principle that application logic exceptions do not get fixed if logic is retried)
Installation Guidelines for Workflow Templates/Frameworks and Snippets can be found here. Please make sure you install the packages mentioned in the Dependencies section before you use this Workflow.