Search code examples
servicesimulationblocknew-operatoranylogic

Anylogic 'service block' one at a time


I'm new with anylogic so I'm not sure how to do this simple thing but is there a way for the service block to only do one agent at a time? I'm making a simulation but it seems that if one agent goes to the service block, it will be serviced even if there is still another agent being serviced? I don't know how to stop the new agent when there is still an agent being serviced. Please help me. Thanks


Solution

  • the problem is probably because you have not set any resources for service block. if you define a resource for your service block, only one agent can be processed at one time and other agents would wait in queue until the delay of first agent is finished.