|
@@ -202,11 +202,12 @@ class VertxMqttConnection implements MqttConnection {
|
|
|
boolean hasDownstream = this.messageProcessor.hasDownstreams();
|
|
boolean hasDownstream = this.messageProcessor.hasDownstreams();
|
|
|
if (autoAckMsg || !hasDownstream) {
|
|
if (autoAckMsg || !hasDownstream) {
|
|
|
publishing.acknowledge();
|
|
publishing.acknowledge();
|
|
|
- this.publishingFluxSink.next(publishing);
|
|
|
|
|
- }
|
|
|
|
|
- if (hasDownstream) {
|
|
|
|
|
- this.publishingFluxSink.next(publishing);
|
|
|
|
|
|
|
+// this.publishingFluxSink.next(publishing);
|
|
|
}
|
|
}
|
|
|
|
|
+ this.publishingFluxSink.next(publishing);
|
|
|
|
|
+// if (hasDownstream) {
|
|
|
|
|
+// this.publishingFluxSink.next(publishing);
|
|
|
|
|
+// }
|
|
|
})
|
|
})
|
|
|
//QoS 1 PUBACK
|
|
//QoS 1 PUBACK
|
|
|
.publishAcknowledgeHandler(messageId -> {
|
|
.publishAcknowledgeHandler(messageId -> {
|
|
@@ -237,9 +238,10 @@ class VertxMqttConnection implements MqttConnection {
|
|
|
if (autoAckSub || !hasDownstream) {
|
|
if (autoAckSub || !hasDownstream) {
|
|
|
subscription.acknowledge();
|
|
subscription.acknowledge();
|
|
|
}
|
|
}
|
|
|
- if (hasDownstream) {
|
|
|
|
|
- this.subscriptionProcessor.onNext(subscription);
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ this.subscriptionProcessor.onNext(subscription);
|
|
|
|
|
+// if (hasDownstream) {
|
|
|
|
|
+// this.subscriptionProcessor.onNext(subscription);
|
|
|
|
|
+// }
|
|
|
})
|
|
})
|
|
|
.unsubscribeHandler(msg -> {
|
|
.unsubscribeHandler(msg -> {
|
|
|
ping();
|
|
ping();
|
|
@@ -248,9 +250,10 @@ class VertxMqttConnection implements MqttConnection {
|
|
|
if (autoAckUnSub || !hasDownstream) {
|
|
if (autoAckUnSub || !hasDownstream) {
|
|
|
unSubscription.acknowledge();
|
|
unSubscription.acknowledge();
|
|
|
}
|
|
}
|
|
|
- if (hasDownstream) {
|
|
|
|
|
- this.unsubscription.onNext(unSubscription);
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ this.unsubscription.onNext(unSubscription);
|
|
|
|
|
+// if (hasDownstream) {
|
|
|
|
|
+// this.unsubscription.onNext(unSubscription);
|
|
|
|
|
+// }
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
|
|
|