You can only specify one role in Akka 2.3.x.
In 2.4-M2 you can use different settings for each entity type. E.g. User
enities can run on nodes with roleX and ShoppingCart enities can run on
nodes with roleY.
fre 7 aug 2015 kl. 17:33 skrev Yifei <sunyifei1...@gmail.com>:

> Thanks Patrik,
>
> Can i define multiple roles in akka.contrib.cluster.sharding.role?
>
> If I have a dispatcher shard region, which starts multiple different
> proxies and dispatches messages to those shardregions via the proxy, how
> should I define the akka.contrib.cluster.sharding.role?
>
> If I understand correctly, it should contain all the roles of the
> different proxies, but this attribute only allows a single string because I
> got this error "role has type LIST rather than STRING"
>
>
> On Friday, August 7, 2015 at 2:28:47 AM UTC-4, Patrik Nordwall wrote:
>
>> The purpose of the role is to define that the shards are only supposed to
>> run on a subset of the nodes, the ones tagged with the specified role. If
>> you start it on a node that does not have this role it will be started in
>> proxy only mode.
>>
>> By the way, we have changed this in 2.4-M2 to make the usage of roles and
>> proxy only more obvious.
>>
> On Thu, Aug 6, 2015 at 5:44 PM, Yifei <sunyif...@gmail.com> wrote:
>>
> After I set akka.contrib.cluster.sharding.role to the same role in
>>> akka.cluster.role, it works.
>>>
>>> What does akka.contrib.cluster.sharding.role mean?
>>>
>>>
>>> On Thursday, August 6, 2015 at 11:37:28 AM UTC-4, Yifei wrote:
>>>>
>>>> Hi,
>>>>
>>>> I have two seeds nodes up in my cluster. When I tried to start a new
>>>> shard region, there is always no oldest state actors, and I don't know
>>>> where the coordinator is located
>>>>
>>>> The log looks like this:
>>>>
>>>> [INFO] [08/06/2015 11:23:31.684]
>>>> [OMSAkkaCluster-akka.actor.default-dispatcher-20] 
>>>> [akka.tcp://MyCluster@abc:13598/user/sharding/Test1Coordinator]
>>>> ClusterSingletonManager state change [Start -> Younger]
>>>>
>>>> Is there any properties I must set? For example, the roles property
>>>>
>>>> Thanks,
>>>>
>>>> --
>>> >>>>>>>>>> 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.
>>> To post to this group, send email to akka...@googlegroups.com.
>>>
>>
>>> Visit this group at http://groups.google.com/group/akka-user.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>>
>> Patrik Nordwall
>> Typesafe <http://typesafe.com/> -  Reactive apps on the JVM
>> Twitter: @patriknw
>>
>> --
> >>>>>>>>>> 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 http://groups.google.com/group/akka-user.
> For more options, visit https://groups.google.com/d/optout.
>
-- 
/Patrik

-- 
>>>>>>>>>>      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 http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to