Progress bar on ACT microflow

Hi All,   I have a scenario wherein one action button on UI has a microflow configured to run on button click. This microflow has multiple APIs executed one after other - in form of sub microflows. I've a progress bar configured on the microflow settings of that action button.    After the first API executed successfully, there is a message pop up on UI for the user. The pop up is waiting (the progress bar is still shown on the UI) until all the sub microflows are executed and the microflow is ended completely.   Only the first API is user-driven and with a custom UI message. Once this is done, all the other APIs should be executed one by one. I can't think of anything else other than sub microflows though to achieve this.    I do want the progress bar to stop displaying so that the user can see the custom success message once the first API call execution is complete. Any suggestions or work arounds here?
1 answers

Hi Sridevi,


Technically, a microflow is "one call" from the client (browser) and its response contains the "Show message", so that explains why you get the message at the end.


I see two solutions which probably solve your challenge:

  1. Let the execution of the other submicroflows happen in one or more tasks in the Task Queue (if it should be one-by-one, make it one big submicroflow to execute in background). The downside could be that the execution is separate from the users session, so both failure and successmessages cannot be passed back to the user anymore
  2. Make use of a main nanoflow to call the submicroflows. In the Nanoflow commons module you can show and hide the progress bar (make sure you also call the hide in the error-handler). This actually breaks up the request in multiple calls. Be careful with credentials and other secrets, they should stay unknown in the nanoflow if you don't want to expose them to the user.

If the users' session is relevant, then I would go for option 2.

If security should be most strict, then I would go for option 1.

If these aren't relevant, both options should work fine.