Hi Rajesh,

On Wed, Jan 21, 2015 at 12:45 AM, Rajesh Shetty <[email protected]> wrote:

> Here is the layman understanding
>
> Cluster -> network of nodes
> nodes -> Physical or virtual instances on a single hardware boxes.
> Essentially which means you can have more than 1 node on a same physical
> box . which means more than one node can have same IP address but MUST have
> different port.
>
> Now this solves the general understanding of cluster/nodes in a typical
> web app scale.
>
> Does akka follow same convention ?.  Question is when you specify
> following application.conf for seed nodes
>
>     seed-nodes = [
>       "akka.tcp://[email protected]:2551",
>       "akka.tcp://[email protected]:2552"]
>
> which means it starts 2 nodes , adds it to the cluster. Now the question
> is if have bunch of actors, do they get created for each of the nodes? e.g
> if have created 4 actors as a part of the process, will I have 8 actors of
> type 4 in each nodes ?. is that a right assumption ?
>

Seed node is a node that is going to be contacted to join a cluster. Node
here means an instance of ActorSystem. This list should contain addresses
of the nodes that have already been started.

If you are starting a node that is going to be the first one to form a
cluster, you should include address of itself to the seed node list, so the
node "joins" itself and forms the initial cluster.


>
> Next question is routers and routees
>
> As I understand each of these actors can be a router . ACTOR > Router and
> router can create child actors a.k.a routees.  So lets say if I use above
> example out of 4 , I make 2 actors as routers (not sure how to make them
> router) and each router creates 4 more child actors (routees) . Which means
> in my cluster I will have
>
> Node1 - 4 actors ; 2 routers , 2 regular actors
>              > 2 router creates > 4 child actors (routees ) each. ->
>  Node1 total actors : 8
> Node2- 4 actors ; 2 routers , 2 regular actors
>              > 2 router creates > 4 child actors (routees ) each. ->
>  Node1 total actors : 8
>
> So total actors in a given cluster 16 . is that a right assumption or
> calculation.?
>
> In short Cluster -> (1-n) Nodes  (physical or virtual ) -> (1-1) Routers
> -> (1-n) Routees
>

Router can be either a pool router
<http://doc.akka.io/docs/akka/2.3.9/scala/routing.html#Pool>, which means
that the router will create and manage its routees, or a group router
<http://doc.akka.io/docs/akka/2.3.9/scala/routing.html#Group>, which means
that routees have already been created and such a router will use paths to
route messages across to routees.

Routers do not count as a regular actors. Routing logic is implemented in
the ActorRef itself
<http://doc.akka.io/docs/akka/2.3.9/scala/routing.html#How_Routing_is_Designed_within_Akka>
.


>
>
>
>
>
>  --
> >>>>>>>>>> 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 [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/d/optout.
>



-- 
Martynas Mickevičius
Typesafe <http://typesafe.com/> – Reactive
<http://www.reactivemanifesto.org/> Apps on the JVM

-- 
>>>>>>>>>>      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 [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/d/optout.

Reply via email to