[akka-user] How to share routers across multiple actors.

2015-07-30 Thread binoj bhaskaran
I have a need to create multiple pool of actors. I plan to create a router for each pool. The flow is Master Actor -> Router A -> Router B -> Router C. How do I create each router in the master actor and share it across or is there a better way to do it ? -- >> Read the docs: http:

Re: [akka-user] Is this the correct flow to retrieve bytes from an HttpResponse?

2015-07-30 Thread john . vieten
the usecase is getting a "complete" ByteString from a from HttpResponse. I joinded a BidiFlow ( above code shows this BidiFlows bottom channel) with Http.get().cachedHostConnectionPool() Flow Am Donnerstag, 30. Juli 2015 08:54:22 UTC+2 schrieb √: > > What's the use-case? > > -- > Cheers, > √ >

[akka-user] what happens when I use a supervison strategie Resume or Restart on a pool flow?

2015-07-30 Thread john . vieten
when I have in my flow Http.get(system).cachedHostConnectionPool(..) or Http().superPool(...); If I define on the whole flow a error supervison strategie, Lets say a connection failed or timeout error happens. 1) what happens if I return Supervision.Resume? 2) what happens if I return Supervi

Re: [akka-user] Is this the correct flow to retrieve bytes from an HttpResponse?

2015-07-30 Thread Viktor Klang
so if the user sends 4gb you want to load it all into memory and crash the jvm? :-) What's the use-case where you can't stream it? -- Cheers, √ On 30 Jul 2015 10:31, wrote: > the usecase is getting a "complete" ByteString from a from HttpResponse. > > I joinded a BidiFlow ( above code shows t

[akka-user] PersistentFSMActor and non persistent events

2015-07-30 Thread Julien Jean Paul Sirocchi
Hi all, I'm experimenting w/ akka 2.4-M2 PersistentFSMActor trait and I've a use case where I'd like to model my persistent actor state's data as a class that gets updated by *both* persistent events *and* non-persistent ones (i.e. I would like to have one container to cater for both persistent

Re: [akka-user] Is this the correct flow to retrieve bytes from an HttpResponse?

2015-07-30 Thread john . vieten
I think you may be showing me an error in my design. the HttpResponse contains json which I then decode back to java Objects. These json payloads will never be 4 gb more 500kb - 10MB but I could be receiveing a lot concurrently which could add up I need to find a way to avoid folding with respo

Re: [akka-user] Is this the correct flow to retrieve bytes from an HttpResponse?

2015-07-30 Thread Viktor Klang
Happy hAkking! -- Cheers, √ On 30 Jul 2015 12:25, wrote: > I think you may be showing me an error in my design. > the HttpResponse contains json which I then decode back to java Objects. > These json payloads will never be 4 gb more 500kb - 10MB but I could be > receiveing a lot concurrently w

Re: [akka-user] Is this the correct flow to retrieve bytes from an HttpResponse?

2015-07-30 Thread john . vieten
yeah the streams api has really taken me (-: it reminds me of flow programming or go blocks or clojure async Am Donnerstag, 30. Juli 2015 13:41:22 UTC+2 schrieb √: > > Happy hAkking! > > -- > Cheers, > √ > On 30 Jul 2015 12:25, > wrote: > >> I think you may be showing me an error in my design.

[akka-user] Different entry actors under a ShardRegion

2015-07-30 Thread Yifei
The use case is that I have production version and development version of an actor I want to route some traffic of this shardregion to dev actors Can I spawn different entry actors(pod and dev) according to the shardId/actorId under a shardregion? Thanks -- >> Read the docs: http

Re: [akka-user] Requester 2.0 library released

2015-07-30 Thread Justin du coeur
Compositional construction of your functions, mainly. pipeTo gets the data to where it needs to be in order to work safely, but you wind up writing a separate clause in your receive to handle that response, at which point ask() isn't gaining all that much over simply doing tells back and forth. Yo

Re: [akka-user] [akka-streams] Consuming on TCP server side - is this really the best way?

2015-07-30 Thread Derek Wyatt
These examples, and the new documentation page, are extremely helpful. Thank you /very/ much. I’m continuing to read / digest / modify them to get a better understanding, but they’ve already cleared up a lot for me. One thing that popped out was the use of |Flow.transform()|. The difference be

Re: [akka-user] Different entry actors under a ShardRegion

2015-07-30 Thread Justin du coeur
Patrik is the expert, but looking at the API and code as it currently stands, I doubt it. To make this possible seems like it would require some restructuring of Cluster Sharding so that you could pass in a "PropsExtractor", corresponding to the Shard and Id Extractors, which would return differen

Re: [akka-user] [akka-streams] Consuming on TCP server side - is this really the best way?

2015-07-30 Thread Endre Varga
Hi Derek, On Thu, Jul 30, 2015 at 6:48 PM, Derek Wyatt wrote: > These examples, and the new documentation page, are extremely helpful. > Thank you *very* much. I’m continuing to read / digest / modify them to > get a better understanding, but they’ve already cleared up a lot for me. > > One thin

[akka-user] How split a flow?

2015-07-30 Thread john . vieten
How do I split a flow? For example if I have a Source of ints that I want to split in even and uneven. Do I have to connect it to a graph(Broadcast.create(2)) and then filter on each of out channels? -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >>>

Re: [akka-user] How split a flow?

2015-07-30 Thread Konrad Malawski
Hi there, you could do it like you mention (pseudocode): Broadcast ~> Flow[].filter(even) ~> Broadcast ~> Flow[].filter(odd) ~> However we have a built-in that serves those kinds of "route things depending on something" situations well: FlexiRoute Here are the docs for it:  http://doc.akka.io/do

Re: [akka-user] Different entry actors under a ShardRegion

2015-07-30 Thread Yifei
Thanks Justin, If Akka doesn't support different actors under a shard region, Can I overwrite ShardCoordinator and define the routing logic in the coordinator? For example, perhaps I can launch two ShardRegions such as SR and SR_DEV, the coordinator of SR redirects the message id ended with 0 t

Re: [akka-user] Different entry actors under a ShardRegion

2015-07-30 Thread Patrik Nordwall
Perhaps use an intermediate actor as the entity actor and it can route messages to child prod/dev actors? Or use an intermediate actor in front of two different shard region actors and it can route the messages to the appropriate prod/dev shard region? /Patrik tors 30 jul 2015 kl. 21:28 skrev Yi

[akka-user] Akka for agar.io clone

2015-07-30 Thread Kamil
Hi. I'm new to akka and I was wondering if akka would be suitable choice for simple clone of game like agar.io (multiplayer, real time 2d). Any suggestions are very welcome. Thanks in advance. -- >> Read the docs: http://akka.io/docs/ >> Check the FAQ: >> htt

Re: [akka-user] Akka Streams - Issue with processing different length streams through drop/zip

2015-07-30 Thread Lance Arlaus
Following is a running sample of what I was talking about. Happy to help, however I'd ask that you please start a new thread with related questions since this conversation is not related to the original thread (you've hijacked the thread). The sample code performs normalization of a stream of in

[akka-user] Akka streams - Balancing jobs to a flexible pool of workers

2015-07-30 Thread Nikita Melkozerov
Hi all, I saw a great docs about balancing jobs to a fixed pool of workers , but if I'm not mistaken it's impossible to add some new workers to the already create