Cluster Configuration Reference
Bondy configuration options controlling cluster formation including automatic peer discovery and performance options.
Listener options
Defines a list of ip_address:port
this node will use to listen for incoming cluster connections. The value accepts the following input strings:
cluster.listen_addrs = 192.168.50.174:18086
cluster.listen_addrs = [192.168.50.174:18086]
cluster.listen_addrs = 192.168.50.174:18086, 192.168.50.180:18086
cluster.listen_addrs = [192.168.50.174:18086, 192.168.50.180:18086]
This option also accepts IP addresses without a port.
cluster.listen_addrs = 192.168.50.174
cluster.listen_addrs = [192.168.50.174]
In this cases the port will be the value of the cluster.peer_port option.
If this option is provided, Bondy will ignore cluster.peer_ip and cluster.peer_port but notice that cluster.peer_port might still be required for some discovery strategies used by Peer Discovery e.g. dns
discovery which will only discover the peer IP addresses but not the ports in which they are listening.
Default
If this option is missing, the IP Address will defaul to the value of cluster.peer_ip option, unless is also missing, in which case the nodename's (BONDY_ERL_NODENAME
environment variable) host part will be used to determine the IP address.
The port will default to the value of cluster.peer_port.
TIP
This options allows multiple values in case you should want to listen on multiple interfaces.
However, normally you will use a single network interface. In that case we recommend disabling this option (by commenting it in your bondy.config
file) and setting the BONDY_ERL_NODENAME
environment variable using a fully-qualified host name e.g. bondy@bondy1.mycluster.local
.
Notice the cluster.peer_port might still be required for other Bondy features. Check the option documentation.
The IP address to use for the peer connection listener when option cluster.listen_addrs has not been defined.
Default
If a value is not defined (and cluster.listen_addrs) was not used, Bondy will attempt to resolve the IP address using the nodename (BONDY_ERL_NODENAME
environment variable) by parsing the right the part to the @
character in the nodename, and will default to 127.0.0.1
if it can't.
The port number to use for the peer connection listener for the cluster TCP/TLS connections.
This value has two main purposes:
- Define the port in which the node will listen for the cluster named channel connections (TCP or TLS) when option cluster.listen_addrs have not been defined.
- Define the port in which peer nodes will listen when using a Peer Discovery strategy that does not provide port number e.g. DNS.
TIP
For production environments we recommend setting the BONDY_ERL_NODENAME
environment variable using a fully-qualified host name e.g. bondy@bondy1.mycluster.local
and always setting the same value for peer_port
on all peers.
cluster.peer_port = 18086
However, if you want to make use of cluster.listen_addrs to listen to connections on multiple network interfaces, we recommend always setting the same value for peer_port
on all peers, and having at least one address in cluster.listen_addrs
having the same port value.
cluster.listen_addrs = [192.168.50.174:18086]
cluster.peer_port = 18086
Deprecated in 1v1.0.0-rc.1
Use the following options instead:
The default channel's parallelism. This channel is used when the other channels are down.
The default channel's compression option. This channel is used when the other channels are down.
The data channel's parallelism.
This channel is used to replicate and synchronise the router's configuration and state data amongst the cluster nodes.
The control_plane channel's compression options.
This channel is used to replicate and synchronise the router's configuration and state data amongst the cluster nodes.
The control plane channel's parallelism.
This channel is used to disseminate cluster membership and control messages.
The control_plane channel's compression options.
This channel is used to disseminate cluster membership and control messages.
The wamp_relay channel's parallelism.
This channel is used to route RPC and PubSub requests across the cluster e.g. WAMP.
The wamp_relay channel's compression options.
This channel is used to route RPC and PubSub requests across the cluster e.g. WAMP.
If enabled then the cluster connection will be established over TLS (making the remaining TLS options mandatory). Otherwise, it will be established over TCP/IP. The default value is off
.
TIP
We recommend enabling this option for production use.
Default signing authority location for cluster TLS connection.
Default cert location for cluster TLS connection. The default value is $(platform_etc_dir)/cert.pem
.
Default key location for cluster TLS connection.
Peer Discovery / Automatic Join
Defines whether Bondy should actively search for peer nodes using a defined strategy.
Defines the module responsible for implementing the node discovery strategy. At the moment only options is bondy_peer_discovery_dns_agent
.
Defines whether Bondy will automatically join a discovered node forming a cluster.
Defines the time duration Bondy will wait between automatic join attempts.
Defines the time duration Bondy will wait between polling attempts.
Defines the time duration Bondy will wait for a response for a polling attempt.
The time the agent will wait to initiate the next join attempt. For this to take effect cluster.peer_discovery.automatic_join needs to be on.
The configuration for the selected strategy in cluster.peer_discovery.type
. Refer to each strategy documentation.
Example: The selected type requires two params keyA
and keyB
.
cluster.peer_discovery.config.keyA = valueA
cluster.peer_discovery.config.keyB = valueB
The configuration for the selected strategy in cluster.peer_discovery.type
. Refer to each strategy documentation.
Example: The selected type requires two params keyA
and keyB
where the latter takes an array of values.
cluster.peer_discovery.config.keyA = value1
cluster.peer_discovery.config.keyB._ = value2
cluster.peer_discovery.config.keyB._ = value3
Topology
WARNING
At the moment the only option is fullmesh
.
Membership View Sync
- document
Automatic leave
Defines whether a Bondy node should perform a cluster leave operation automatically when it is being shutdown.