Configuration Reference
All connector options are set as Reactive Messaging channel attributes, using the following key format:
mp.messaging.[incoming|outgoing].<channel-name>.<attribute>=<value>
For example, to set the QoS of the outgoing channel topic-price:
mp.messaging.outgoing.topic-price.connector=smallrye-mqtt-hivemq
mp.messaging.outgoing.topic-price.qos=1
The connector attribute must always be set to smallrye-mqtt-hivemq. Only host is mandatory (and it can be provided automatically by Dev Services in dev/test mode).
| The tables below group the attributes by purpose. For the raw, complete list see Full attribute list. Security options are explained in depth in Security & TLS, and health-check options in Health Checks. |
Connection
| Attribute | Description | Type | Default |
|---|---|---|---|
|
MQTT server host name or IP. Mandatory. |
string |
|
|
MQTT server port. |
int |
|
|
SNI (Server Name Indication) server name. |
string |
|
|
MQTT client identifier. |
string |
|
|
Generate a random |
boolean |
|
|
Connection timeout, in seconds. |
int |
|
Authentication & TLS
See Security & TLS for complete, worked examples.
| Attribute | Description | Type | Default |
|---|---|---|---|
|
Username for MQTT simple authentication. |
string |
|
|
Password for MQTT simple authentication. |
string |
|
|
Enable SSL/TLS. |
boolean |
|
|
Trust every server certificate. Insecure — development only. |
boolean |
|
|
Truststore type ( |
string |
|
|
Truststore location (required when |
string |
|
|
Truststore password (required when |
string |
|
|
Keystore type ( |
string |
|
|
Keystore location. Enables mutual TLS. |
string |
|
|
Keystore password (also used as the private-key password). |
string |
|
|
Verify that the server certificate matches the hostname. Set to |
boolean |
|
Session & keep-alive
| Attribute | Description | Type | Default |
|---|---|---|---|
|
Start with a clean MQTT session. |
boolean |
|
|
Keep-alive timeout, in seconds. |
int |
|
|
Let the client answer |
boolean |
|
Messaging & QoS
| Attribute | Description | Type | Default |
|---|---|---|---|
|
Topic to subscribe/publish to. Defaults to the channel name. |
string |
|
|
QoS level ( |
int |
|
|
Maximum MQTT message size, in bytes. |
int |
|
|
Maximum number of unacknowledged messages in flight. |
int |
|
|
(incoming only) Dispatch each received message to all subscribers. |
boolean |
|
|
(incoming only) Behaviour when a message is nacked: |
string |
|
|
(outgoing only) Allow the channel to have multiple upstreams. |
boolean |
|
Last will
The Last Will and Testament is published by the broker if the client disconnects unexpectedly.
| Attribute | Description | Type | Default |
|---|---|---|---|
|
Send will information on connection. |
boolean |
|
|
Retain the will message on the broker. |
boolean |
|
|
QoS level of the will message. |
int |
|
Reconnection
The underlying HiveMQ client always reconnects automatically. These options tune the retry behaviour.
| Attribute | Description | Type | Default |
|---|---|---|---|
|
Maximum number of reconnect attempts. |
int |
|
|
Interval between reconnect attempts, in seconds. |
int |
|
Health checks
See Health Checks for details.
| Attribute | Description | Type | Default |
|---|---|---|---|
|
Enable the readiness/liveness health check. |
boolean |
|
|
Topic used by the health check. |
string |
|
|
Time (ms) without a message before the client is not ready. |
int |
|
|
Time (ms) without a message before the client is not alive. |
int |
|
Dev Services (build time)
Dev Services are configured with quarkus.hivemq.devservices.* build-time properties — see Dev Services.
Full attribute list
The following tables are generated from the connector’s @ConnectorAttribute definitions and list every option, per direction.
| Attribute | Description | Type | Default |
|---|---|---|---|
|
MQTT server host name/IP. Mandatory. |
string |
|
|
MQTT server port. |
int |
|
|
SNI server name. |
string |
|
|
Client identifier. |
string |
|
|
Generate the |
boolean |
|
|
Username used to connect to the broker. |
string |
|
|
Password used to connect to the broker. |
string |
|
|
Enable SSL/TLS. |
boolean |
|
|
Trust every server certificate (insecure). |
boolean |
|
|
Truststore type ( |
string |
|
|
Truststore location. |
string |
|
|
Truststore password. |
string |
|
|
Keystore type ( |
string |
|
|
Keystore location — used for mTLS. |
string |
|
|
Keystore password — used for mTLS. |
string |
|
|
Enable SSL hostname verification. Set to |
boolean |
|
|
Start with a clean session. |
boolean |
|
|
Keep-alive timeout, in seconds. |
int |
|
|
Let the client handle |
boolean |
|
|
Connect timeout, in seconds. |
int |
|
|
MQTT topic to subscribe to. If not set, the channel name is used. |
string |
|
|
QoS level used when subscribing. |
int |
|
|
Max MQTT message size, in bytes. |
int |
|
|
Max count of unacknowledged messages. |
int |
|
|
Dispatch the received messages to multiple consumers. |
boolean |
|
|
Strategy applied when a message is nacked: |
string |
|
|
Provide will information on connection. |
boolean |
|
|
Retain the will message. |
boolean |
|
|
QoS level of the will message. |
int |
|
|
Max reconnect attempts. |
int |
|
|
Reconnect interval, in seconds. |
int |
|
|
Enable the liveness/readiness health check. |
boolean |
|
|
Topic used for the health check. |
string |
|
|
Timeout (ms) before the client is declared not ready. |
int |
|
|
Timeout (ms) before the client is declared not alive. |
int |
|
| Attribute | Description | Type | Default |
|---|---|---|---|
|
MQTT server host name/IP. Mandatory. |
string |
|
|
MQTT server port. |
int |
|
|
SNI server name. |
string |
|
|
Client identifier. |
string |
|
|
Generate the |
boolean |
|
|
Username used to connect to the broker. |
string |
|
|
Password used to connect to the broker. |
string |
|
|
Enable SSL/TLS. |
boolean |
|
|
Trust every server certificate (insecure). |
boolean |
|
|
Truststore type ( |
string |
|
|
Truststore location. |
string |
|
|
Truststore password. |
string |
|
|
Keystore type ( |
string |
|
|
Keystore location — used for mTLS. |
string |
|
|
Keystore password — used for mTLS. |
string |
|
|
Enable SSL hostname verification. Set to |
boolean |
|
|
Start with a clean session. |
boolean |
|
|
Keep-alive timeout, in seconds. |
int |
|
|
Let the client handle |
boolean |
|
|
Connect timeout, in seconds. |
int |
|
|
MQTT topic to publish to. If not set, the channel name is used. |
string |
|
|
QoS level used when publishing. |
int |
|
|
Max MQTT message size, in bytes. |
int |
|
|
Max count of unacknowledged messages. |
int |
|
|
Allow multiple upstreams for the channel. |
boolean |
|
|
Provide will information on connection. |
boolean |
|
|
Retain the will message. |
boolean |
|
|
QoS level of the will message. |
int |
|
|
Max reconnect attempts. |
int |
|
|
Reconnect interval, in seconds. |
int |
|
|
Enable the liveness/readiness health check. |
boolean |
|
|
Topic used for the health check. |
string |
|
|
Timeout (ms) before the client is declared not ready. |
int |
|
|
Timeout (ms) before the client is declared not alive. |
int |
|