Major refactoring of RemoteActorRefProvider, remote Routing and FailureDetector, including lots of fixes and improvements.
- Decoupled FailureDetector from Routing by introducing ConnectionManager which uses FailureDetector instead of it being the same thing. - Added ConnectionManager - Added LocalConnectionManager - Added RemoteConnectionManager - Improved RoutedProps - Integrated and added configuration for Scatter Gather router - Added NoOpFailureDetector - Misc API and documentation improvements Signed-off-by: Jonas Bonér <jonas@jonasboner.com>
This commit is contained in:
parent
78193d7a62
commit
4ec050c12e
23 changed files with 870 additions and 995 deletions
|
|
@ -9,7 +9,7 @@ import akka.event.EventHandler
|
|||
import System.{ currentTimeMillis ⇒ now }
|
||||
import akka.routing.Routing.Broadcast
|
||||
import akka.actor.{ Timeout, Channel, Actor, PoisonPill }
|
||||
import akka.routing.{ RoutedProps, Routing }
|
||||
import akka.routing._
|
||||
|
||||
object Pi extends App {
|
||||
|
||||
|
|
@ -53,7 +53,9 @@ object Pi extends App {
|
|||
val workers = Vector.fill(nrOfWorkers)(actorOf[Worker])
|
||||
|
||||
// wrap them with a load-balancing router
|
||||
val router = Routing.actorOf(RoutedProps().withConnections(workers).withRoundRobinRouter, "pi")
|
||||
val router = Routing.actorOf(RoutedProps(
|
||||
routerFactory = () ⇒ new RoundRobinRouter,
|
||||
connectionManager = new LocalConnectionManager(workers)), "pi")
|
||||
|
||||
// phase 1, can accept a Calculate message
|
||||
def scatter: Receive = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue