0
votes

I want to let a queue block to send a message to a seize block. This message should be sent every 150 agents that pass through the queue block and let a resource seize more agents.

I am however, uncertain on how a count can be involved, is my idea even possible?

1

1 Answers

0
votes

Your question is very strange, because making a resource seize more agents, means that the resource can work on many agents at the same time right? To do that you have to create batches. I think you are totally asking the wrong question or lacking details, but here goes a potential help.

model structure

you will add a variable queueCounter as an integer with initial value 0; in the exit action of the queue you do queueCounter++; to count the agent that just passed. a select output block will batch the agents if queueCounter>500 you can decide how many agents you want to batch (meaning the agents that the resource can work at the same time)

At some point you have to stop batching and get back to normal making queueCounter=0; but it's uncertain for me when you should do that. Not enough info in your question.

Don't forget to unbatch at the end.