increase paho inflight message limit (#970)

Signed-off-by: Jan N. Klug <jan.n.klug@rub.de>
pull/973/head
J-N-K 2019-08-12 11:08:39 +02:00 committed by Christoph Weitkamp
parent 921c1c1004
commit a17d63ad64
1 changed files with 3 additions and 1 deletions

View File

@ -717,7 +717,9 @@ public class MqttBrokerConnection {
// Connect
_client.setCallback(clientCallback);
try {
_client.connect(createMqttOptions(), null, connectionCallback);
MqttConnectOptions mqttConnectOptions = createMqttOptions();
mqttConnectOptions.setMaxInflight(16384); // 1/4 of available message ids
_client.connect(mqttConnectOptions, null, connectionCallback);
logger.info("Starting MQTT broker connection to '{}' with clientid {} and file store '{}'", host,
getClientId(), persistencePath);
} catch (org.eclipse.paho.client.mqttv3.MqttException | ConfigurationException e) {