paho.mqtt.javascript icon indicating copy to clipboard operation
paho.mqtt.javascript copied to clipboard

Error: AMQJS0016E Invalid MQTT message type 0

Open ngocdb opened this issue 8 years ago • 1 comments

I'm using Paho Mqtt on react-native. However, I receive the error every time I connect to mqtt server. I can sure the host, port are OK, the clientId is unique.

Object {invocationContext: undefined, errorCode: 16, errorMessage: "AMQJS0016E Invalid MQTT message type 0."}

How can I debug the error, please help...

ngocdb avatar Jul 25 '17 03:07 ngocdb

I tested up to the 0.45.0 version

... "react": "16.0.0-alpha.12", "react-native": "0.45.0", ...

and it still runs well.

But it fails with the 0.46.4 version. Check the release notes, I see there is a change with websocket in the latest version.

Added Cookie Header to XML and Websocket request (047961f)

Not sure how this thing affect the mqtt connect ?

ngocdb avatar Jul 25 '17 10:07 ngocdb