when send only one message to broker,there is error as follow。
正在进行过多的发布
(32202)
at org.eclipse.paho.mqttv5.client.internal.ClientState.send(ClientState.java:544)
at org.eclipse.paho.mqttv5.client.internal.ClientComms.internalSend(ClientComms.java:155)
at org.eclipse.paho.mqttv5.client.internal.ClientComms.sendNoWait(ClientComms.java:218)
at org.eclipse.paho.mqttv5.client.MqttAsyncClient.publish(MqttAsyncClient.java:1530)
at org.eclipse.paho.mqttv5.client.MqttAsyncClient.publish(MqttAsyncClient.java:1499)
the reason is the server return receiveMaximum as 65535, and MqttProperties#decodeProperties use readShort to read value ,the result is -1, so cause the problem。 shoule use readUnsignShort instead to read receiveMaximum value
when send only one message to broker,there is error as follow。 正在进行过多的发布 (32202) at org.eclipse.paho.mqttv5.client.internal.ClientState.send(ClientState.java:544) at org.eclipse.paho.mqttv5.client.internal.ClientComms.internalSend(ClientComms.java:155) at org.eclipse.paho.mqttv5.client.internal.ClientComms.sendNoWait(ClientComms.java:218) at org.eclipse.paho.mqttv5.client.MqttAsyncClient.publish(MqttAsyncClient.java:1530) at org.eclipse.paho.mqttv5.client.MqttAsyncClient.publish(MqttAsyncClient.java:1499)
the reason is the server return receiveMaximum as 65535, and MqttProperties#decodeProperties use readShort to read value ,the result is -1, so cause the problem。 shoule use readUnsignShort instead to read receiveMaximum value