Hi
I have a strange problem when reuse an actor, (the error is random!)
This is my scenario:
- send 40 async request (messages) to my principal actor.
- principal actor send every single request (message) to 10 secondary
actors.
- secondary actors reply to an assembler actor who collect the results and
send the final result.
I resuse every time same actor in this way:
private ActorRef getActor(String actorName) {
Option<ActorRef> child = getContext().child(actorName);
if(child.isDefined())
return child.get();
else
return
getContext().actorOf(SpringExtProvider.get(getContext().system()).props(actorName).withRouter(new
SmallestMailboxRouter(4)), actorName);
}
(this is "like" store actors in map or cache, its correct?!)
and this is the error that return to me in random way at execution time:
[ERROR] [02/03/2014 18:40:19.248]
[OrchestrationApplication-akka.actor.default-dispatcher-2]
[akka.dispatch.Dispatcher] actor name [actorName1] is not unique!
* akka.actor.InvalidActorNameException*: actor name [actorName1] is not
unique!
at
akka.actor.dungeon.ChildrenContainer$NormalChildrenContainer.reserve(ChildrenContainer.scala:130)
...
[ERROR] [02/03/2014 18:40:19.248]
[OrchestrationApplication-akka.actor.default-dispatcher-2]
[akka.dispatch.Dispatcher] actor name [actorName2] is not unique!
* akka.actor.InvalidActorNameException*: actor name [actorName2] is not
unique!
at
akka.actor.dungeon.ChildrenContainer$NormalChildrenContainer.reserve(ChildrenContainer.scala:130)
...
etc etc...
why this error? if the actor is defines (also actor name) why system try
to recreate actor?
I think that if an actor dead or is stopped also his name is removed of
actopr system, or not?
ps:
my dispatcher is default dispatcher, and I have a 4 core processor (i5)
teh default config for dispatcher is:
fork-join-executor {
parallelism-min = 8
parallelism-factor = 3.0
parallelism-max = 64
}
throughput = 10
its correct?
tnx!
carlo
--
>>>>>>>>>> Read the docs: http://akka.io/docs/
>>>>>>>>>> Check the FAQ: http://akka.io/faq/
>>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
---
You received this message because you are subscribed to the Google Groups "Akka
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.