There is no easy way to achieve this Johanna, as you know the process runs on the RR, so stopping the RR means stopping the session. So the first problem is how to start another session after the RR has restarted. The second (easier) problem is how to have that next session pick up where the first one finished.
It might be possible to use the scheduler's 'On Exception' task, but care is needed to avoid creating an infinite loop where a process fails and the task restarts again and again.
Another option is to have the first session make a delayed command line call just before the process ends. The command line call will keep 'counting down' after the process has ended. Here you can see an example with a 5 second timeout.
This means if you use a timeout long enough to allow the RR to restart, then the command to run the next session should succeed. You could probably create a single command that does everything, eg:
- Wait for current session to end (eg 5s)
- Restart RR
- Wait for RR to connect and become available (eg 30s)
- Start process again
Using the command line means you'll need to think about authentication, security and permissions, but if you create a user with minimal permissions then you can reduce the risks. And assuming you use a work queue then the first session can control the state of the last case it works on before initiating the restart. the next session should just be able to pick the next case and carry on.
------------------------------
John Carter
Professional Services
Blue Prism
------------------------------