mateen rajid
mateen rajid

Reputation: 43

Indepth MQTT's topic

I've used MQTT Paho libraries before using Python. What actually happens when a topic was established? e.g "home/kitchen/lights".

Does the program create folders based on the topic? Since it uses slash as a separator. Or does the program store the topic as a string?

Upvotes: 0

Views: 50

Answers (1)

hardillb
hardillb

Reputation: 59608

Nothing on the client side, in fact most client libraries don't even keep a list of the topics they are subscribed (the client library doesn't need to know once it's sent the request to the broker).

On the broker it entirely depends on the implementation, it could be a list of strings, it could be a tree structure.

A topic is not a file path just because it uses a / doesn't mean it has anything to do with paths.

Upvotes: 1

Related Questions