I am creating a BPT (Business Process Technology) process in OutSystems.
I understand that the Service Center provides an automatic/manual retry mechanism for failed BPT activities. However, I do not want to rely on the Service Center retry behavior. Instead, I would like to control the retry logic within the BPT process itself.
Is there any built-in or recommended mechanism to retry failed BPT activities without using the Service Center retry?
If not, what is the best practice for implementing an automatic retry mechanism for BPT processes (for example, using timers, retry counters, or custom error-handling logic)?
I would really appreciate it if anyone could share their experience, design patterns, or recommended approaches for handling automatic retries in BPT. Any guidance or examples would be very helpful. Thank you in advance.
Hello,
If we’re talking about built-in retries, this is already handled by OutSystems. When a BPT process fails, it automatically retries until it succeeds. As you mentioned, this behavior can be monitored from Service Center.
However, when it comes to controlling the retry mechanism, there is no built-in feature for that, as far as I know. A possible workaround is to implement custom logic inside the automatic activities of the process. For example, you can use a local counter variable that increments on each execution and, once it reaches a predefined limit, terminates the process.
Keep in mind that this is not an official approach but rather a workaround. As a result, a new instance of the automatic activity is created each time the activity is retried, which you will see in Service Center. Additionally, the process remains in a Running state and is neither suspended nor terminated automatically. In the background, it keeps retrying based on your custom logic.
In other words, OutSystems does not recognize this as a native retry mechanism, so this trade-off should be carefully considered.
Thank you very much for taking the time to share your insights and recommendations. I sincerely appreciate your help and will try your suggested approach.
You’re very welcome anytime.
If his recommendation can solve your issue, please mark his comment as solution
Thank you so much for your detailed advice. It helped me understand the issue clearly, and I have now resolved the problem using your approach.
I’m really, really happy it helped you 😄 You’re more than welcome anytime.