How to customize re framework to dispatcher bot to catch system and business exception

How to customize re framework to create dispatcher bot to catch system and business exception.

Hello @Aleem_Khan

  • The easiest way is to have two projects (1 dispatcher, 1 performer) then you can take advantage of the built-in exception handling logic.
  • Alternatively, you can create your own dispatcher framework with a state machine using a similar logic:
  1. Create a State Machine
  2. Add “States” to get data, process, handle exceptions and an End State
  3. Create global SystemException and BusinessRuleException variables
  4. Add try-catch sequences inside each state
  5. configure the catches to capture both System.Exception and BusinessRule Exception and send the exceptions to your global variables
  6. Assign your transition conditions accordingly, for example if you want to route to an exception handler you can use something like If SystemException isnot Nothing or BusinessException isnot Nothing

This is an example of a custom built framework using a state machine
image

try-catch example
image

Transition example
image

Example of error handler by type

Can you please share me xaml file appreciate you