IMPORTANTIf any EIP configuration is not available in the form, you can adjust it directly in the main.yaml file. To do so, access the Source Code tab and edit the integration code.
The doTry EIP allows you to create integration flows involving a process in a "Try" block. It creates doCatch and doFinally branches to handle specific exceptions and ensure that certain actions are executed at the end, regardless of errors. With this, failures can be handled in a controlled manner, ensuring that the flow execution continues without unnecessary interruptions.
To configure a doTry in an integration in the Diagram tab, follow these steps:
Click +Add Step on the canvas.
Select the EIPs tab.
Select the doTry EIP. You can use the search tool to locate it.
When adding the EIP to the canvas, three branches will be automatically created:
NOTEYou can add other "doCatch" type branches by clicking "+" and then Add Handling Step.
There are three deletion scenarios for the doTry EIP and its branches:
When deleting a "doCatch" block, all steps in that branch will be removed.
When deleting a "doFinally" block, all steps in that branch will be removed.
When deleting a doTry EIP, all blocks and subsequent steps will be removed.

The flow starts with a timer, which is triggered every 60 seconds to query orders from an ERP.
The flow attempts to access the ERP to get orders and process them with doTry. The order is then sent directly to the financial system and the status is updated in the ERP.
If there are connection errors, such as ConnectException or SocketTimeoutException, these errors will be captured with doCatch, logged, and a notification will be sent to the IT team.
Regardless of whether the flow was successful or failed, the integration process will be finalized with an audit record and a log generation with doFinally.
Check the example in code format:
We use cookies to enhance your experience on our site. By continuing to browse, you agree to our use of cookies.Learn more