Search code examples
javadistributed-computingakkamessage-passing

Distributed nature task and Akka


This is a simplified version of my problem:

  1. On the server we have n*m - matrix of type int[][], we split this matrix into the set of n row-vectors and put them in a queue.
  2. When the queue is ready (full of vectors), we loop over and send each vector to one of the k clients somewhere on the network if and only if the client is free to take the vector (some client-status checking in a form of message-passing will be handy).
  3. All clients do the same thing with a given vector - they compute the norm (length) of a vector and send the result back to the server where it is stored.
  4. When all the clients are finished, the server prints the results on the machine where the initial Job has been launched.

I'm going to use Akka distributed computation framework with Java. Could you please tell me where to start learning the Akka tools, because I do not yet know how to use it. Actors will probably be those clients..


Solution

  • Akka has a getting-started tutorial that computes Pi by a process very similar to what you've described.

    There's also of course a Scala version.