Commit a48d0dea authored by Tim Molderez's avatar Tim Molderez

Increased timeout for attach agent

parent f16fb132
......@@ -36,11 +36,11 @@ defmodule Marlon.Actor do
# Attaches an agent for the given goal to this actor
def attach_agent(actor, goal) do
GenServer.call(actor, {:attach_agent, goal, goal})
GenServer.call(actor, {:attach_agent, goal, goal}, 30000) # The goal module itself acts as a group here!
end
def attach_agent(actor, goal, group) do
GenServer.call(actor, {:attach_agent, goal, group})
GenServer.call(actor, {:attach_agent, goal, group}, 30000)
end
# Removes an agent from this actor
......@@ -94,6 +94,10 @@ defmodule Marlon.Actor do
{:reply, state.marlon_agents}
end
def handle_call(:get_state, _from, state) do
{:reply, state, state}
end
def handle_cast(:do_action, state) do
Enum.map(state.marlon_agents,
fn(agent) -> Marlon.Agent.do_action(agent) end)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment