Re: [akka-user] [Akka stream] Sink/source materialization

2017-02-09 Thread hbf
On Wednesday, February 8, 2017 at 12:25:25 AM UTC-8, √ wrote: > > You mean like: Source.single(()).flatMapConcat(_ => yourFunction())? > Cool, that works. I also see Source.unfoldResource, which I missed before and seems super useful. I was more struggling with the sink-side: is there a primit

[akka-user] Re: Akka: How to get Children actor on Restart

2017-02-09 Thread Achin Gupta
My use case is: Before restart, there are let say 5 children of a parent. Now, i wish to calculate performance and to calculate performance i need participation from all these 5 children. So, after restart, i could just send the same message to all children, after which children will work and

Re: [akka-user] About Akka persistent redis

2017-02-09 Thread Dai Yinhua
Well, I'm using below maven settings as the document provided. com.hootsuite akka-persistence-redis_2.11 0.6.0 On Thursday, 9 February 2017 21:38:49 UTC+8, Justin du coeur wrote: > > Hmm. I don't know the library, but I notice that it seems to require a > custom Bintray resolver. Have

Re: [akka-user] Help: how to persist different actor types in different shard regions?

2017-02-09 Thread Qing Zheng
I disagree, you have all the pieces of your system, however, they are not fit well with each other at least that's how I feel from a user point of view. Just like you have database tableA and tableB, the ID in tableA has nothing to do with ID in tableB. This may not be a good analogy, but you g

Re: [akka-user] How to get materialized values from a custom Sink

2017-02-09 Thread Andrew
Thanks! I decided to make the sink into a flow so I could fold and get the total elements processed but good to know about GraphStageWithMaterializedValue On Wed, Feb 8, 2017 at 2:37 PM Konrad Malawski < konrad.malaw...@lightbend.com> wrote: > It's documented here: > http://doc.akka.io/docs/akka/

[akka-user] Re: Akka: How to get Children actor on Restart

2017-02-09 Thread Achin Gupta
Thank you for the reply. And, i understand that in preRestart, the parent unwatches the child. And, hence if i override this method to do nothing, i should get the context.children() value correct. But when i tried doing so, i still see empty collection. Not sure what i am doing wrong. On Th

[akka-user] Re: Akka: How to get Children actor on Restart

2017-02-09 Thread Rafał Krzewski
Check preRestart method implementation as described in http://doc.akka.io/docs/akka/2.4/scala/actors.html#Actor_API It should answer your question :) Cheers, Rafał W dniu czwartek, 9 lutego 2017 17:18:24 UTC+1 użytkownik Achin Gupta napisał: > > When the System is restarted, the context.childre

[akka-user] Struggling with custom Akka HTTP directive

2017-02-09 Thread Elliot Wright
I started out with, quite honestly, a stupid idea. However, once I started it I wanted to see it through to learn from it and hopefully gain some insight into how you might actually write a directive. I've discovered a few things in the process, but have no idea why these things are the way the

[akka-user] Akka: How to get Children actor on Restart

2017-02-09 Thread Achin Gupta
When the System is restarted, the context.children() call returns zero children for a particular parent. Before restart, context.children() returned the actual count of children that parent had. Can someone please let me know how can we get the children ActorRef for a parent after restart? -

[akka-user] Re: Can I use Akka for such kind of architecture?

2017-02-09 Thread Rafał Krzewski
The client in private network opens the connection to the server in DMZ. WebSocket protocol allows bi-directional communication: the server may push messages the the client, and akka-http / akka-streams ensure backpressure propagation. W dniu czwartek, 9 lutego 2017 14:32:59 UTC+1 użytkownik C

[akka-user] Re: The Akka system keeps Disassociating

2017-02-09 Thread johannes . rudolph
Hi Gang, disassociation usually means some kind of connection error. Unfortunately, akka currently doesn't say anything about why a connection was closed. This will be improved in the next version. See https://github.com/akka/akka/pull/22278 Johannes On Wednesday, February 8, 2017 at 12:04:19

Re: [akka-user] Help: how to persist different actor types in different shard regions?

2017-02-09 Thread Justin du coeur
Persistence and sharding are separate systems -- while they work well together, neither depends upon the other. So it would be inappropriate for persistence to depend on knowledge of which sharding region an Actor is in... On Wed, Feb 8, 2017 at 11:54 AM, Qing Zheng wrote: > Hi Patrik, > > My

Re: [akka-user] About Akka persistent redis

2017-02-09 Thread Justin du coeur
Hmm. I don't know the library, but I notice that it seems to require a custom Bintray resolver. Have you added that to your sbt file? On Wed, Feb 8, 2017 at 9:54 PM, Dai Yinhua wrote: > Hi team, > > Do you ever used the akka persistent redis: https://index.scala- > lang.org/hootsuite/akka-pers

[akka-user] Re: Can I use Akka for such kind of architecture?

2017-02-09 Thread Christian Kaps
Sorry, I meant bidirectional Am Donnerstag, 9. Februar 2017 13:10:06 UTC+1 schrieb Christian Kaps: > > And this would work without any inbound traffic from the DMZ to the > private network? I had firstly the same idea. But then I thought that the > web socket connection must be directional. > >

[akka-user] Re: Can I use Akka for such kind of architecture?

2017-02-09 Thread Christian Kaps
And this would work without any inbound traffic from the DMZ to the private network? I had firstly the same idea. But then I thought that the web socket connection must be directional. Best regards, Christian Am Donnerstag, 9. Februar 2017 12:27:57 UTC+1 schrieb Rafał Krzewski: > > I would prob

[akka-user] Re: Can I use Akka for such kind of architecture?

2017-02-09 Thread Rafał Krzewski
I would probably let the proxy node in DMZ run an akka-http server and publish a WebSocket endpoint. The worker node in private network would connect to it using akka-http client. This is probably the easiest way to stream messages from DMZ to private zone with backpressure and (some degree of)

[akka-user] Re: Can I use Akka for such kind of architecture?

2017-02-09 Thread Christian Kaps
Hi Rafał, Thanks for your answer! Maybe I implement an Akka TCP server which is located in the DMZ and a TCP client which is located in the private network. Is it possible that the client polls message in near real-time from the TCP server? Am I right, that this is possible with Pull-reading as

[akka-user] Re: Can I use Akka for such kind of architecture?

2017-02-09 Thread Rafał Krzewski
Hi Christian, Akka is very general toolkit and you can implement any communication architecture that you need with it. It offers excellent HTTP support and also low-level TCP and UDP communication and you can implement any standard or custom protocol on top of that. Akka Cluster however does no

[akka-user] Can I use Akka for such kind of architecture?

2017-02-09 Thread Christian Kaps
Hi, for a project we need a special type of server architecture. Because of a customer compliance we cannot access the customers database server from the DMZ. The server on which the database runs can access servers inside the DMZ. In a similar project my employee has used a proxy like architec