I have created a very simple model in AnyLogic consisting of source, Service, sink and resourcepool blocks. The source is connected to service which is then connected to sink. The source block generates agents of type 1 and resourcepool has agent type 2. When I run the model, I am getting following runtime error. There are no attributes to both the agent types. Also, agent types are created and not population.
java.lang.NullPointerException
at com.anylogic.engine.Port.connect(Unknown Source)
at com.anylogic.libraries.processmodeling.Seize.doCreate(Unknown Source)
at com.anylogic.engine.Agent.createAsEmbedded(Unknown Source)
at com.anylogic.libraries.processmodeling.Service.doCreate(Unknown Source)
at com.anylogic.engine.Agent.createAsEmbedded(Unknown Source)
at model.Main.doCreate(Main.java.619)
at com.anylogic.engine.Agent.createAsEmbedded(Unknown Source)
at com.anylogic.engine.Agent.create(Unknown Source)
at com.anylogic.engine.Engine.start(Unknown Source)
I tried debugging the model but no success and also verified that all the initializations are not null.
Model: enter image description here
Source properties: enter image description here
Service properties: enter image description here
Resourcepool properties: enter image description here