Skip to content

[Distributed] Configuration

murmex edited this page Jun 1, 2011 · 1 revision

Configuration

As the distributed implementation of the Menthor framework is based on Akka, we can already leverage the internal configuration of Akka through its akka.conf file.

Cluster

What remains is the configuration of the cluster so that the cluster services on the selected nodes can create the required foremen and workers. All the information needed for that tasks are:

  • the hostname/IP and the port of the nodes;
  • the number of workers to instantiate on the node.

The configuration is managed by the GraphMaster that takes a file/arguments where each line has the form

<Hostname|IP>[:<Port>] [[+|*]<Number of workers>]

with only the hostname/IP being mandatory.

A relative number of workers can be specified by using a + or * prefix. The + prefix creates Runtime.availableProcessors plus the specified number workers and the * prefix creates Runtime.availableProcessors times the specified number workers.

Defaults

The use of sane defaults is also important for the configuration.

Firstly, the lack of configuration means that the processing is done in parallel on the local node. The local cluster service, if it exists, is not used and the only option available is the number of workers to create.

When the port of the node is not specified, the port specified in the Akka configuration is used (2552 per default).

Finally, the number of workers instantiated per default on a node correspond to the number of core available on the node as returned by Runtime.availableProcessors.