Error handling on group items processing

Challenge description

Some time ago, a customer requested the solution for frequent SAP backups of crucial transactions data as an additional security measure. Idea was simple – once in every couple hours, bot should run some transactions in SAP, export data to given format and store it on secured SharePoint location where the files would be versioned and be a part of further backups processing using dedicated tool.

Answer

At first glance, process is straightforward as shown in simplified BPMN diagram below:

img1

Of course, each of activities above can fail, and these exceptions should be handled. So, let’s add exception handling:

img2

Voila! Now, in case something happens during execution, our bot will grab details, take screenshots and close SAP before reporting exception to parent flow. Before reaching ecstatic state and implementing our solution with enthusiasm, let’s take a deep breath and go back to beginning. What is the goal of this process? That goal is creating data backups. And what would happen if any of the given transactions processing fails? The remaining ones would be abandoned until next execution, because each error in group processing switches processing to exception handling block which handles safe exit. We can imagine scenario, where one of the transactions produce too much data under given configuration and fails constantly, effectively stopping other transactions for being backed up. So how can we address this issue?

Firstly, it is crucial that all transactions are backed up – in case it is impossible, bot should skip faulty ones and proceed with remaining ones. Secondly, when exception happens, response team should be informed which backups failed to be created. Taking above conditions into account, we can add additional exception handling block, which would work inside group processing, stopping only failed backup processing:

img3

This way, bot handles each processing item individually without interrupting entire flow. On the other hand, exceptions which are critical – like the ones during logging to SAP and it’s restarting – are handled by “external” handling block, which stops further flow processing.

Share the Post:

Contact KTBNet today!

Everything in one place

Related

mkwadrat

Discover how mKWADRAT, a provider of professional property and lease management services, overcame communication challenges and enhanced operational efficiency through a strategic digital transformation. Faced with the need for unified business tools across multiple sites in Poland, mKWADRAT turned to KTBnet for a tailored solution….

Read More

Spektra

Discover how Spektra Group, a leader in personal and property security services since 1996, embarked on a journey to modernize its workplace. Faced with the challenge of enhancing efficiency, the company turned to KTBnet, a trusted Microsoft partner. Through the implementation of Microsoft 365, Power…

Read More