Using Queues for Complex Transactions -- Best Practice?

I’m currently running a Bot that tests phone lines for availability. The bot calls into the phone line, hits a few buttons at the prompt to navigate, and validates the call prompt it hears against an expected prompt. I have this set up through a queue on our Orchestrator, where the bot can get these complex steps/phone numbers/etc for each transaction easily. The transaction data is set up like so:

Phone Number | Buttons to Press | How Long to Listen | Expected Prompt

The problem is that this bot runs these transactions every 15 minutes 24/7 and checks the same X number of lines. When the bot exhausts the transactions in the queue, it re-adds them so it can run them again in 15 minutes. I tend to think this isn’t best practice for our scenario–but I don’t want to lose the convenience of processing transactions through the REFramework.

If anyone has better ideas for how to go about this, I would greatly appreciate it.

Hi @tentekal, welcome to the community!

Have you tried using the postpone/delay activity? You can set a determined amount of time and the transaction will automatically be added back to the queue as “New”. Once the time frame expires, the transaction will automatically be tried.

You can also utilize the ‘Set Transaction Progress’ if that’s helpful. That would be more for a scenario where a robot wouldn’t go through every step listed (Phone Number | Buttons to Press | How Long to Listen | Expected Prompt).

1 Like

There are two approaches to this…

  1. handle each 15mins as a new transaction where the reference includes the timestamp that it would be processing during. This would allow you to know which transactions fail at which times when looking at the analytics. However, this would not be an ideal approach if you want each phone number to be the individual transaction for the analytics.

  2. each time your job runs, it postpones all transactions within a certain time period. I have done this in the past to attempt to retry transactions multiple days in a row to ensure no new data was found in a web application, and works well.

Also note, that setting the transactions “Deadline” in incremental values will prioritize the queue items to pick the earliest deadline first. This is very useful to know in case you want to make sure the queue prioritizes the items correctly.

Regards.

1 Like

Sounds like the second option is certainly the best. If I’m understanding it correctly; I would run the transactions from the queue, and then in “end process” postpone those same transactions to 15 minutes later? This would then set those transactions to New again, and when the Bot runs later it will continue this “loop”.

Yep. Also, the postpone time doesn’t matter. Postpone just changes their state back to “New”, so the next time it runs it will pick them up again.

Perfect, that’s a great solution. Thanks!

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.