This HiveMQ extension allows your HiveMQ cluster nodes to discover each other dynamically by regularly exchanging their information via etcd.
HiveMQ instances are added at runtime as soon as they become available by placing their information, on how to connect to them, to the configured key. The extension will regularly check the configured etcd key for files from other HiveMQ nodes. Additionally every broker updates its own entry on a regular basis to prevent the entry from expiring.
extensions
folder of your HiveMQ nodes.etcdDiscovery.properties
file for your needs or set environment variablesextension
.The information each node writes into etcd consists of an ip-address and a port.
The ip-address and port are taken from the external-address
and external-port
which is configured in the cluster transport
(config.xml). If they are not set, the bind-address
and bind-port
will be used.
The etcdDiscovery.properties
can be reloaded during runtime.
Configuration from etcdDiscovery.properties
will always take precedent over environment variables.
Config name | Environment | Required | Description |
---|---|---|---|
key | HIVEMQ_ETCD_KEY | Key to store discovery entries at | |
etcd-endpoint | HIVEMQ_ETCD_ENDPOINT | x | The region in which this S3 bucket resides. |
etcd-port | HIVEMQ_ETCD_PORT | etcd port to connect at | |
expiration | HIVEMQ_ETCD_EXPIRATION | Time in seconds after which an entry in etcd is considered expired | |
update-interval | HIVEMQ_ETCD_UPDATE_INTERVAL | Time in seconds after which an entry in etcd is refreshed (Must be smaller than file-expiration ) |
|
use-tls | HIVEMQ_ETCD_USE_TLS | Use TLS for connection to etcd | |
ca-path | HIVEMQ_ETCD_CA_PATH | Certificate authority to use for validating tls connection to etcd - if not set, system certificates will be used |
|
|