Why is there STILL no way to delete an In Progress Queue Item?!

We (@otico and I) are recent converts from BluePrism. In BP an in progress queue item can easily be first stopped / aborted and then it can be deleted by the user. The database / queue will retain these queue items. This saved us a lot of time when debugging both during development and production.

However, in UiPath we faced the same issue as metioned by @postwick @nilschr and others.
@bcorrea this is possible, it is just not built-in within UiPath orchestrator GUI.

We looked at this thread and we want to help with a workaround. Our approach is -

  1. Get Queue Items: Get all your queue items with status “InProgress” - Inumerable output
  2. For each QueueItem (Inumerable) - Set Transaction Status to “Failed” with a given Reason in properties tab
  3. Get Queue Items: Get all your queue items with status “Failed” - Inumerable output
  4. For each QueueItem (Inumerable) - Delete Queue Item

We tested it on Orchestrator On-Prem v20.04 and it works :star_struck:. The deleted queue items still showup in the Orchestrator Queue, which is exactly how it should be. It is always best to have this traceability. We did not have to delete the queue.

Here is the solution file: DeleteInProgressQueueItems.xaml (8.2 KB)

:warning: This is a workaround using official queue activities, that said, please ensure that you do not run this flow when one of your robots is running a dispatcher / performer process linked to the same queue. Also, if you use this approach at the end of REFramework (to keep the queue clean), ensure you have necessary routines to identify which items need to be sent to the queue next time the dispatcher runs.

Further improvements
If you want to get the ItemData for the deleted items and add them to the queue as a new Queue Item, this is possible too. All you have to do is parse the inumerable resulting from Step 1 or Step 3 and get the data associated with the failed/deleted item and pass it to the Add to Queue activity accordingly.

Hope this helps!

23 Likes