Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-29 Thread alex . f . reisberg
Here it is: Scalable chat (with presence) on akka Cheers, Alex On Tuesday, December 29, 2015 at 8:40:00 AM UTC-6, Konrad Malawski wrote: > > Let's hop on a new thread with this, would you mind opening one? Thanks :) > > -- > Cheers

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-29 Thread Konrad Malawski
Let's hop on a new thread with this, would you mind opening one? Thanks :) --  Cheers, Konrad 'ktoso’ Malawski Akka @ Typesafe On 28 December 2015 at 21:08:08, alex.f.reisb...@gmail.com (alex.f.reisb...@gmail.com) wrote: @Konrad: Great! It seems that I totally misunderstood what I saw in the ak

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-28 Thread alex . f . reisberg
@Konrad: Great! It seems that I totally misunderstood what I saw in the akka source (which I only took a cursory look and jumped to conclusion too quickly). So just to confirm my understanding: suppose I have a topic named "apple", then pubsub only sends the subscription data of "apple" to node

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-28 Thread Konrad Malawski
But now, there's one thing that I'm not too happy about: both distributed pubsub and distributed data seem to replicate all data onto all nodes instead of spreading out to the cluster.  That's not true – pubsub only sends data to such nodes, which subscribed to a given topic. If all people are

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-28 Thread Konrad Malawski
API simplicity is one thing – runtime, failure and recovery semantics are another, that's there the dragon lies. My only point here is, that it's tricky to have 2 clusters being running in the same jvm, because there's much more failure scenarios you suddenly have to think about:  - what if Akka

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-28 Thread Guido Medina
I was planning to have Hazelcast start/stop with each ActorSystem programmatically, Hazelcast API is as friendly as akka's But again if akka has its own in-memory grid then no need, also think if you only need a counter or other things from a toolkit like Hazelcast and if the things you will ne

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-27 Thread alex . f . reisberg
@Konrad: Thanks for the great answer! Disagreement on failure can indeed be a pain. What I'm trying to do is essentially one of the first exercises one would do with akka: a chat app with online/offline notification. For passing messages around, one option is to use akka's distributed pubsub. T

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-27 Thread Konrad Malawski
Just @Konrad or @ktoso is fine ;-) In order to properly answer we'd have to sit down together and think about your requirements, deployment strategy etc. The short story is: you'll hazlecast maintains it's own cluster, it has some  kind of failure detection. Akka is a cluster, it has some kind o

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-27 Thread alex . f . reisberg
Just realized that due to confusion, I added the "I see. Thanks a lot!" (which was supposed to be for a different thread). I'm still curious to hear more about the comment on Hazelcast. @Konrad 'ktoso’ Malawski: I'm curious about your comment on Hazelcast (because I'm actually thinking of using

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-25 Thread Alex Reisberg
I see. Thanks a lot! On Fri, Dec 25, 2015 at 9:43 AM, wrote: > Exactly, I wouldn't want to add another piece to get those counters for > the test. So I'm definitely gonna use akka's distributed data for this. > > @Konrad 'ktoso’ Malawski: I'm curious about your comment on Hazelcast > (because I

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-25 Thread alex . f . reisberg
Exactly, I wouldn't want to add another piece to get those counters for the test. So I'm definitely gonna use akka's distributed data for this. @Konrad 'ktoso’ Malawski: I'm curious about your comment on Hazelcast (because I'm actually thinking of using it). Suppose I need to maintain distribu

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-25 Thread Konrad Malawski
After having consulted a number of customers who included or previously-had hazlecast clusters along with  Akka apps I remain unconvienced what hazlecast added to the table (other than - "yet another cluster, with different and detached lifecycle to manage"). I'd avoid adding more separate indepe

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-25 Thread Guido Medina
I will need distributed data for my project in the future so it was good you mentioned it cause I didn't know akka had it. -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >> http://doc.akka.io/docs/akka/current/additional/faq.html >> Se

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-25 Thread Konrad Malawski
Without going much deeper – I certainly wouldn't add any of these to a project just to get a CRDT counter ;-) Also, we have those too:  http://doc.akka.io/docs/akka/snapshot/scala/distributed-data.html :-) --  Cheers, Konrad 'ktoso’ Malawski Akka @ Typesafe On 25 December 2015 at 11:22:07, Guido

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-25 Thread Guido Medina
Or CRDT with any distributed data structure, I can mention a couple: Hazelcast, Riak, etc Basically you want a distributed counter. -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >> http://doc.akka.io/docs/akka/current/additional/faq.html

Re: [akka-user] Aggregate counts in multi-jvm testing

2015-12-24 Thread Konrad Malawski
You're in a distributed system – how would you do it there? "The Akka way" of doing it is messaging :-) Send a message to the "cluster actor", which each JVM has,  from the same sender, collect the replies, once you got all of them (and you know, because you know how many questions you've sent),

[akka-user] Aggregate counts in multi-jvm testing

2015-12-24 Thread alex . f . reisberg
Is there any way to combines variables from different jvm's in multi-jvm testing? More concretely, suppose each jvm has a counting variable (which, for eg, counts the number of jobs that have been sent to them), and I want to check that their sums is equal to some number (for eg. the total numb