Chapter 7. MQ Telemetry Transport(MQTT) Protocol
Abstract
URI syntax
Example 7.1. MQTT URI
mqtt://Host:[Port]?transportOptions
Example 7.2. Syntax for MQTT+NIO Connection
mqtt+nio://Host[:Port]?transportOptions
Example 7.3. Syntax for an MQTT SSL Connection
mqtt+ssl://Host[:Port]?transportOptions
Example 7.4. Syntax for a MQTT+NIO SSL Connection
mqtt+nio+ssl://Host[:Port]?transportOptions
Transport options
Table 7.1. MQTT Transport Options
| Property | Default | Description |
|---|---|---|
transport.defaultKeepAlive | 0 |
Specifies, in milliseconds, the broker will allow a connection to be silent before it is closed. If a client specifies a keep-alive duration, this setting is ignored. This option is set in the
uri attribute of a broker's transportConnector element.
|
jms.* | All the properties with this prefix are used to configure client connections to a broker. See Appendix B, Client Connection Options for more information. |
SSL transport options
SSLServerSocket created for the connection. These options are listed in Table 2.1, “SSL Transport Options”.
Configuring broker SSL options
transport.OptionName. For example, to enable an MQTT SSL port on a broker, you would add the following transport element:
<transportConnector name="mqttssl" uri="mqtt+ssl://localhost:61617?transport.enabledProtocols=TLSv1,TLSv1.1,TLSv1.2" />
&, between options as &.
Configuring client SSL options
socket.OptionName. For example, to connect to a MQTT SSL port, you would use a URL like the following:
mqtt+ssl://localhost:61617?socket.enabledProtocols=TLSv1,TLSv1.1,TLSv1.2

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.