In my case single actor may not be fast enough. My actors sometimes deal 
with fairly large latencies depending where in the path they are. To expand 
on my example it is possible that actor 2 does not receive many messages 
from actor1 and capable of processing them quickly, but it receives large 
amount of messages from actor3 and could experience delays in REST 
responses. That's why I would prefer to tweak the routers between each (or 
some) hops.

On Friday, August 19, 2016 at 10:59:39 AM UTC-4, rkuhn wrote:
>
> Why do you conflate the route structure (i.e. the routing hops) with the 
> supervisor hierarchy? This is usually a bad idea. Instead, create your 
> three actors as children of a supervisor that introduces them to one 
> another—and only introduce Routers once you have benchmarked that a single 
> actor is not fast enough.
>
> Regards,
>
> Roland
>
> 19 aug. 2016 kl. 16:23 skrev Mark Kaberman <mkab...@gmail.com 
> <javascript:>>:
>
> Actually I only need 3 entry instead of 5 and I need to name my routers 
> differently:
> /actor1/router1/
> /actor1/router1/actor2/router2
> /actor1/router1/actor3/router2
>
> but the point is still valid: I need to accommodate for all possible path 
> permutations in my routers definition.
>
> On Friday, August 19, 2016 at 10:00:21 AM UTC-4, Mark Kaberman wrote:
>>
>> When I define a router in Akka's application.conf I always need to 
>> specify the router path. If I have multiple possible routes the messages 
>> travel in my application  the configuration file may become very 
>> complicated. An example: I have three actors in my system: actor1, actor 2 
>> and actor3. Actor1 can send messages to 2 and 3. Actor 2 can send messages 
>> to 3 and actor 3 to 1. My understanding it (and I may be completely wrong 
>> here) that I need to define 4 routers in my application.conf to accommodate 
>> for all paths:
>>
>> /actor1/router/actor2
>> /actor1/router/actor3
>> /actor1/router/actor2/router/actor3
>> /actor1/router/actor3/router/actor1
>>
>> That will make my config file complex since I need to take into account 
>> all possible path permutation. I can use a wildcard in order to avoid 
>> specifying an actor name, but the number of elements in the path seems to 
>> have to match the actual number of hops. Is there a way to define default 
>> router(s) in order to avoid overly complex configuration file?
>>
>>
>>
> -- 
> >>>>>>>>>> Read the docs: http://akka.io/docs/
> >>>>>>>>>> Check the FAQ: 
> http://doc.akka.io/docs/akka/current/additional/faq.html
> >>>>>>>>>> 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 akka-user+...@googlegroups.com <javascript:>.
> To post to this group, send email to akka...@googlegroups.com 
> <javascript:>.
> Visit this group at https://groups.google.com/group/akka-user.
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      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 akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at https://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to