Orchestrator Queue Auto Increment?

Hi Experts,

i just want to know if Queue in orchestrator is auto-increment because if yes then i dont need to do TransactionNumber+1 in my sequence.

many thanks,
lyn

Hello @bri

If you want to store a transaction number in the queue as a data element, you will need to use it to identify the unique item.

However, when reading items from the queue, if you are using the Get Transaction Item inside a loop or in REFramework, then you will not need it to individually identify the data element, but you will need it to identify the logs related to each item… so it depends on your need actually…

Hi @Lahiru.Fernando,

im a newbie, so you mean if i will use the orchestrator queue in REFramework i dont need to use loop?

manythanks,
lyn

1 Like

@bri

No… not really… what I meant is, when using the orchestrator queue, you anyway have to use a loop. So if you notice in the activities, there are mainly two activities to get data from a queue.

  1. Get queue items
  2. Get transaction item

Get queue items will give you all the items in the queue at once. For this you can configure items which which status you need to extract… Next you can have a for each loop to loop through the items.

Get transaction item will give only one item at a time of status “new” type. For this, you still need to use a loop. What I wanted to mention is, you dont need to use transaction number variable to refer to a item in the queue. However say you have 10 items in the queue. In the loop, when iterating through each item, if you need to refer which item you are processing, then you might need a transaction number variable that holds the count. This can e set to increment in the loop for each iteration…

Makes sense or did I make you more confused? :thinking:

Hi @bri,

Queue works on the mechanism of FIFO(First In First Out).
So when you use Get Transaction Item it picks the first item from the queue to process it and get the item out from the queue.
Now, when you use Get Transaction Item next time. It will pick up the second item from the queue because the first item is already processed(eliminated).

So, to process all transaction item in the queue, we use Get Transaction Item in the loop.

Transaction Number is a variable which will be used to notify in the logs which transaction is being processing at that moment
It’s not mandatory to provide Transaction number value every time
You can assign any value to this variable , may be any unique column of each transaction , so that you will easily identify which record is getting processed at that particular time