[akka-user] Re: how to get the number of actors from actor system?

2017-03-21 Thread Dai Yinhua
Sending ShardRegion.GetClusterShardingStats to a local shard region can get all shard regions, and their shards and underlying entities. On Wednesday, 22 March 2017 10:53:27 UTC+8, Leo Wolf wrote: > > Hi there, > > I have constructed the shard region in actor system, but I wonder if > there's an

[akka-user] how to get the number of actors from actor system?

2017-03-21 Thread Leo Wolf
Hi there, I have constructed the shard region in actor system, but I wonder if there's any way to know the number of entity actors in the system, or get the number of all actors in whole actor system? If I count it with a counter, then if the actor system crashed and restarted, I will lose coun

[akka-user] Is Akka Multi Node Testing available in Java

2017-03-21 Thread Dai Yinhua
Anybody knows how to run akka multi node testing in java? Is there any example code? -- >> 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.googl

Re: [akka-user] How to group a list of actors in Akka?

2017-03-21 Thread kant kodali
I think I understand it better from what you said. I guess I don't have separate parent for each group therefore I was looking to see how to group the child actors but anyways since it is not the standard approach from what you are saying I would not go that way. I believe I can leverage event bus

Re: [akka-user] How to group a list of actors in Akka?

2017-03-21 Thread Justin du coeur
Not sure I understand the desired use case, but I believe the answer is no -- the *path* of an Actor has to be unique. That is, for a given parent, only one child may have a given name. Is there a reason not to just have the parent maintain separate lists of the different groups? You seem to be

Re: [akka-user] How to group a list of actors in Akka?

2017-03-21 Thread kant kodali
Can two actors have the same name? For Example, Can I create same instance of Actor class in a For loop so I can access all the actors by that name? On Tue, Mar 21, 2017 at 6:12 AM, Justin du coeur wrote: > Right -- that's probably the way I would tend to construct something like > this, but it

Re: [akka-user] How to group a list of actors in Akka?

2017-03-21 Thread Justin du coeur
Right -- that's probably the way I would tend to construct something like this, but it would depend on the use case, as well as whether the "groups" in question were mutually exclusive... On Tue, Mar 21, 2017 at 9:05 AM, Konrad Malawski < konrad.malaw...@lightbend.com> wrote: > > As such, no -- t

Re: [akka-user] How to group a list of actors in Akka?

2017-03-21 Thread Konrad Malawski
As such, no -- there's no formal "group" concept like this, although you could construct it manually yourself. There is "all children of given actor" which is accessible by context.children() inside an Actor. -- Konrad `ktoso` Malawski Akka @ Lightbend

Re: [akka-user] How to group a list of actors in Akka?

2017-03-21 Thread Justin du coeur
As such, no -- there's no formal "group" concept like this, although you could construct it manually yourself. I suspect this use case is usually handled with PubSub -- each group subscribes to an appropriate channel. (But I don't use this myself, so can't say for sure.) On Tue, Mar 21, 2017 at

[akka-user] Apply different functions on SubFlows

2017-03-21 Thread Vishal John
Hello all, I have defined my application flow like this, *val flow = Flow[StringConsumerRecord].* * map(tup => new Ticket(tup.value.toLong)).* * mapConcat(applyBusinessLogic(_)).* * groupBy(4, _._1).* * groupedWithin(100, 5.second).* * mergeSubstreams.* * throttle(1, 1.second, 1, Throttle

[akka-user] How to group a list of actors in Akka?

2017-03-21 Thread kant kodali
Hi All, How to group a list of actors? I want to send message A to group of Actors M and message B to group of Actors N. Is there a way to give them a common name and access them through that name so I can send my messages? or Is there any better way? Thanks! -- >> Read the docs

Re: [akka-user] Re: How to listen to events on CassandraJournalProvider ?

2017-03-21 Thread 'Michal Borowiecki' via Akka User List
Hi kant, You can browse the sources on github. The implementation doesn't seem to leverage anything from Cassandra underneath, the journal plugin does the work itself. When asked to persist events, it emits (throttled) notifications via akka pubsub which the CassandraReadJournal subscribes to.