[akka-user] Message does not get sent from akka-http route to akka Actor

2015-08-18 Thread William Bezuidenhout
Hi In light of the the route testkit module not having the JUnitTestRoute class. I thought I would try to test using with JavaTestKit. Test setup: system = ActorSystem.create(); probe = new JavaTestKit(system); webAPI = new WebAPI(actorRef); webAPI.bindRoute(localhost, 8080, this.system);

[akka-user] Re: Specs2RouteTest equivalent for Akka HTTP

2015-08-18 Thread Johannes Rudolph
Hi, specs2 testing support hasn't been ported from spray yet. The basic issue is that akka modules weren't allowed to depend on Scala dependencies because of bootstrapping issues when releasing a new Scala version that includes Akka. I'm not completely sure if this is still the most recent

[akka-user] How to achieve concurrency in akka and handle global state

2015-08-18 Thread Atin Sood
Hi I am new to learning akka and I am looking into a problem of trying to create a movie hall reservation system. I am trying to wrap my head around how to achieve concurrency with akka. If I end up creating multiple instances of akka actors then where/how should I share the global state

[akka-user] Re: Update is an unhandled message on PersistentView?

2015-08-18 Thread delasoul
Your views are sharded - to send a message to a view the corresponding ShardRegion needs an ID - Update has no ID. You found the right solution:) hth, michael On Tuesday, 18 August 2015 05:01:57 UTC+2, Bill Goldsworthy wrote: I was able to resolve this by doing the following in my

[akka-user] akka-http client unable to reuse a tcp connection (aka connection pipelining)

2015-08-18 Thread yar . ilich
Hi, I'm trying to get akka-http client to pipeline HTTP requests in one TCP connection. I rewrote what was based on Http().singleRequest into this: (path(batch-geocode) put entity(as[Map[String, String]])) { br = val connectionPool = Http().cachedHostConnectionPool[String](geocoder.ca)

[akka-user] Re: How to achieve concurrency in akka and handle global state

2015-08-18 Thread Brian Thibault
Whole idea is no global state... remember actors are an abstraction that allow you to build distributed, concurrent systems. Concurrency in general is bad with shared state. Each Actor can maintain its own state. One easy idea might be to create an actor to encapsulate some state you want

Re: [akka-user] Exception while shuting down Akka Cluster with Singleton on it.

2015-08-18 Thread Patrik Nordwall
On Tue, Aug 18, 2015 at 6:41 PM, Danny Lesnik danny.les...@gmail.com wrote: Thanks Patrick, but my ActorSystem crashes after it. in what way does the ActorSystem crash? how did you see that it crashed? It becomes unavailable in JMX and calling joinSeedNodes has no effect at all. If it

[akka-user] Re: Persistent actor partitioning question

2015-08-18 Thread Dan Di Spaltro
Any ideas here? I was curious how others approached the high-number-of-journals in akka/kafka land. Thanks! On Wednesday, August 12, 2015 at 5:06:43 PM UTC-7, Dan Di Spaltro wrote: So imagine I am building a session tracking system. Where I am feeding the session header, events, and other

[akka-user] [Review request] Probabilistic domain service idempotency with HyperLogLog

2015-08-18 Thread Grzegorz Duszyński
I'm evaluating an approach to domain service idempotency using HyperLogLog [ *HLL*]. Aim of this approach would be to provide generic way of ensuring idempotency without storing large amounts of useless information. Only requirement being tolerance for occasional duplication (send 2 email

Re: [akka-user] Re: Specs2RouteTest equivalent for Akka HTTP

2015-08-18 Thread Everson Alves da Silva
Awesome, I will give that a try. Thanks Adam. On Tuesday, August 18, 2015 at 11:02:02 AM UTC-3, Adam Shannon wrote: FYI If you want to add a class to your application here's an example: https://gist.github.com/adamdecaf/f83c7000d1b69bc29c4d On Tue, Aug 18, 2015 at 2:29 AM, Johannes Rudolph

[akka-user] Re: How to achieve concurrency in akka and handle global state

2015-08-18 Thread Atin Sood
Re posting since I wasn't able to get any feedback on the last post. On Tuesday, August 18, 2015 at 4:16:36 AM UTC-4, Atin Sood wrote: Hi I am new to learning akka and I am looking into a problem of trying to create a movie hall reservation system. I am trying to wrap my head around

Re: [akka-user] Re: Specs2RouteTest equivalent for Akka HTTP

2015-08-18 Thread 'Johannes Rudolph' via Akka User List
Thanks Adam. On Tue, Aug 18, 2015 at 4:01 PM, Adam Shannon adam.shan...@banno.com wrote: FYI If you want to add a class to your application here's an example: https://gist.github.com/adamdecaf/f83c7000d1b69bc29c4d On Tue, Aug 18, 2015 at 2:29 AM, Johannes Rudolph

Re: [akka-user] Re: Specs2RouteTest equivalent for Akka HTTP

2015-08-18 Thread Adam Shannon
FYI If you want to add a class to your application here's an example: https://gist.github.com/adamdecaf/f83c7000d1b69bc29c4d On Tue, Aug 18, 2015 at 2:29 AM, Johannes Rudolph johannes.rudo...@googlemail.com wrote: Hi, specs2 testing support hasn't been ported from spray yet. The basic issue

Re: [akka-user] Exception while shuting down Akka Cluster with Singleton on it.

2015-08-18 Thread Patrik Nordwall
This is fixed in 2.4-M3. The exception is harmless. tis 18 aug 2015 kl. 18:23 skrev Danny Lesnik danny.les...@gmail.com: I have a cluster of 5 nodes, due to the problems with network infrastructure I might have network partition. As the result my cluster may split into several subclusters.

Re: [akka-user] Exception while shuting down Akka Cluster with Singleton on it.

2015-08-18 Thread Danny Lesnik
Thanks Patrick, but my ActorSystem crashes after it. It becomes unavailable in JMX and calling joinSeedNodes has no effect at all. On Tuesday, August 18, 2015 at 7:38:34 PM UTC+3, Patrik Nordwall wrote: This is fixed in 2.4-M3. The exception is harmless. tis 18 aug 2015 kl. 18:23 skrev

[akka-user] Exception while shuting down Akka Cluster with Singleton on it.

2015-08-18 Thread Danny Lesnik
I have a cluster of 5 nodes, due to the problems with network infrastructure I might have network partition. As the result my cluster may split into several subclusters. The way to recognize such cases I'm running singleton Actor, which writes current cluster state to zookeeper, as soon as I

[akka-user] Re: Update is an unhandled message on PersistentView?

2015-08-18 Thread Bill Goldsworthy
OK, that makes sense. Thanks for the feedback. On Tuesday, August 18, 2015 at 2:30:20 AM UTC-5, delasoul wrote: Your views are sharded - to send a message to a view the corresponding ShardRegion needs an ID - Update has no ID. You found the right solution:) hth, michael On Tuesday, 18

[akka-user] Re: How to achieve concurrency in akka and handle global state

2015-08-18 Thread Johan Andrén
Hi Atin, A very central idea when working with actors is to not share any mutable state, instead mutable state is encapsulated inside of the actors. If one actor needs to know something about the state of another actor it will ask for it using immutable messages and get an immutable reply.