0

this image contains mqtt parameters

parameters

this image contains topic & message

topic & message

this image contains the error

Error

Any insights on how to connect these problem ?

Thanks!

student
  • 3
  • 2

1 Answers1

0

the problem is on subscription action. Devices (user use-token-auth) cannot subscribe on topics such as iot-2/evt/event_id/fmt/format_string (e.g iot-2/evt/abc/fmt/json).

Devices can only publish to the event topics in the following format:

iot-2/evt/event_id/fmt/format_string

and devices can only subscribe to command topics in the following format:

iot-2/cmd/command_id/fmt/format_string

You have more details about that here

Remove the subscribing action, or change topic to smth like iot-2/cmd/abc/fmt/json and it should be ok.

idan
  • 554
  • 6
  • 19
  • I deactivate the subscription and i change the topic of publisher **iot-2 / evt / status / fmt / json** but the problem still exists : Invalid userID () for device auth: ClientID = 'd: hykxz8: test: test', ClientIP = 41.231.56.98, ClientPort = 5242, ConnectionId = 25550972 – student Sep 15 '20 at 11:25
  • do you see the Invalid userID() during connection or publish action? – idan Sep 16 '20 at 05:27
  • during publish action – student Sep 16 '20 at 11:15
  • does the test device connect over a gateway? the invalid userID() shows up if the user provided for the connection is empty(null). – idan Sep 18 '20 at 14:36