Customising the auto-configuration

You can use command line arguments or environment variables to customise the name of the nodes or the way they are clustered.

Customising node names

To customise the name of a node, use either of the following:

  1. The -node argument
    sse start -node foo@127.0.0.1
    Important: If you give your nodes a host name that is different from your machine's host name, be sure to use the -contact argument when creating clusters, otherwise the newly-created nodes cannot find the contact node. By default, the auto-configuration assumes that all nodes' host name is the same as your machine's host name.
  2. The NODE environment variable
    export NODE=bar@127.0.0.1
    sse start
    Tip: See Linux environment variables for further details.

Figure 1 illustrates:

  • The possible scenarios for defining the node's name
  • The sequence of these scenarios
  • The fallback used if the node name was not specified.

Figure 2 illustrates the way the default name is decided.

Figure: Configuring node name


Figure: Default naming of nodes


Customising contact nodes

To specify which node your newly-created node should contact, use either of the following:

  1. The -contact argument
    sse start -contact foo@127.0.0.1
  2. The CONTACT environment variable
    export CONTACT=bar@127.0.0.1
    sse start
    Tip: See Linux environment variables for further details.

Figure 3 illustrates:

  • The possible scenarios for defining the node that the newly-created node contacts
  • The sequence of these scenarios
  • The fallbacks used if the contact node was not specified.

Figure: Configuring contact nodes