MQTT – A lightweight messaging protocol
Just like REST, pub/sub is one of the most popular messaging patterns, mostly deployed to transfer short messages between nodes. Instead of deploying client-server-based architecture, the pub/sub paradigm implements messaging middleware called a broker to receive, queue, and relay messages between the subscriber and publisher clients:
The pub/sub architecture utilizes a topic-based system to select and process messages, where each message is labeled with a specific topic name. Instead of sending a message directly to the subscriber, the publisher sends it first to the broker with a topic name. In a totally independent process, the subscriber registers its subscription for particular topics with the broker. In the event of receiving a message from the publisher, the broker performs topic-based filtering on that message before forwarding it to the subscribers registered for that topic. As publishers are loosely coupled to subscribers in this architecture...