Features Overview¶
Pulse MQTT extends Eclipse Paho with production-ready features that make MQTT integration robust and maintainable.
What Makes Pulse MQTT Different?¶
1. Auto-Subscription Support¶
Automatically resubscribe to topics after reconnection. No manual subscription tracking needed.
Benefit: Ensures message delivery continuity without writing reconnection logic.
2. Health Monitoring¶
Periodic connection health checks detect and recover from stale connections.
Benefit: Prevents silent connection failures in production.
3. Network Monitoring¶
Automatic reconnection when network connectivity is restored.
Benefit: Seamless recovery from network disruptions without manual intervention.
4. QoS Level Support¶
Full MQTT QoS 0, 1, and 2 support with per-topic configuration.
TopicTypeConfig(
messageType = Data::class.java,
qosLevel = QOSLevel.QOS_1 // At least once delivery
)
Benefit: Configure delivery guarantees per use case - QoS 0 for logs, QoS 1 for metrics, QoS 2 for critical data.
5. Built-in Retry Policies¶
Intelligent retry strategies with exponential backoff and exception filtering.
RetryPolicy.exponential(
maxRetries = 5,
baseDelayMillis = 2000,
excludedExceptionCodes = hashSetOf(
MqttExceptionCode.REASON_CODE_NOT_AUTHORIZED
)
)
Benefit: Prevents thundering herd problems and avoids retrying unrecoverable errors.
6. Dependent Command Architecture¶
Chain commands with dependencies - subscribe waits for connect automatically.
Benefit: Eliminates race conditions and manual state management.
7. Type-Safe Message Handling¶
Automatic JSON to Kotlin class deserialization.
override fun onMqttMessageReceived(
topic: String?,
payload: String?,
topicMessage: TopicMessage<*>?
) {
val data = topicMessage?.message as? SensorData
}
Benefit: Type safety and no manual JSON parsing.
Feature Comparison¶
| Feature | Eclipse Paho | Pulse MQTT |
|---|---|---|
| MQTT Protocol | ✅ | ✅ |
| Auto-Subscription | ❌ | ✅ |
| Health Monitoring | ❌ | ✅ |
| Network Monitoring | ❌ | ✅ |
| Retry Policies | ❌ | ✅ |
| Command Dependencies | ❌ | ✅ |
| Type-Safe Messages | ❌ | ✅ |
| QoS Support | ✅ | ✅ Enhanced |
Learn More¶
- Auto-Subscription - Automatic topic resubscription
- Health Monitoring - Connection health checks
- Network Monitoring - Network-aware reconnection
- QoS Levels - Quality of Service configuration
- Retry Policies - Intelligent retry strategies