0
votes

I and new to Akka & want to achieve this,

  1. want to deploy few Stateful actors on fixed machines (Which will be always on) and stateless actors (Processing actors/workers) on Amazon EC2 Spot instances

Now to handle failover of Stateful actors deciding to use Akka persistance.

And to distribute job on stateless workers deciding to use RoundRobinPool with remotely deployed routees. And want messages to be passed to least utilized machine (CPU & Memory). Using Pool so that I can use withSupervisorStrategy() for handling Actor Failure.

I am going through example for Remote Deployeed Routees & refering to this code http://www.typesafe.com/activator/template/akka-sample-cluster-java. And https://github.com/akka/akka/blob/cb05725c1ec8a09e9bfd57dd093911dd41c7b288/akka-samples/akka-sample-cluster-java/src/main/java/sample/cluster/stats/StatsSampleOneMasterMain.java.

In StatsSampleClient it is randomly taking node & passing message. I want to pass it least utilized maching as mentioned above. I want to know whether Akka support this or I will have write code to find out utilization & send message to that machine accordingly.

Kindly suggest if any better approach can used for what I have mentioned above.

Thanks!

-Devendra

1

1 Answers

0
votes

Did you have a look at the Adaptive Load Balancing Router?

It performs load balancing of messages to cluster nodes based on the cluster metrics data by configuration.

Hope it helps.