MQTT 3.1.1
MQTT 3.1.1 implementation in MAPS Messaging.
Features
- QoS 0, 1, 2
- Retained messages
- Last Will and Testament (LWT)
- Clean / Persistent sessions
Quick Start
protocols:
mqtt:
version: "3.1.1"
port: 1883
Configuration (3.1.1)
Fields below map to the common MQTT configuration (
MqttConfigDTO). Properties specific to MQTT 5 (e.g., topic aliases, receive maximum) do not apply to 3.1.1.
| Field | Type | Default | Description |
|---|---|---|---|
maximumSessionExpiry | long (s) | 86400 | Upper bound for session expiry; 3.1.1 uses clean session semantics, but MAPS enforces an internal cap for persistence windows. |
maximumBufferSize | long (bytes) | 10485760 | Max per-connection buffer before backpressure. |
strictClientId | boolean | false | Enforce spec-compliant client IDs (reject empty/invalid). |
Example with guards
protocols:
mqtt:
version: "3.1.1"
port: 1883
maximumBufferSize: 1048576 # 1 MiB
maximumSessionExpiry: 86400
strictClientId: true