B4J Question Mqtt broker list of topics

giggetto71

Active Member
Licensed User
Longtime User
Hi
Is there a way for a mqtt client to get the list of all the topics of a mqtt broker ? I know a client can connect to multiple topics using #, but i would to list them all. Is that possibile?
Thanks
 

giggetto71

Active Member
Licensed User
Longtime User
ok thanks. when one client subscribes to all topics (#) I guess it starts receiving messages from all topics. Is it then possible, once I get the message, to get the name of that specific topic from the message?
 
Upvote 0

LucaMs

Expert
Licensed User
Longtime User
ok thanks. when one client subscribes to all topics (#) I guess it starts receiving messages from all topics. Is it then possible, once I get the message, to get the name of that specific topic from the message?

The event MessageArrived returns the related topic.

B4X:
Private Sub mqtt_MessageArrived (Topic As String, Payload() As Byte)
 
Upvote 0
Top