Improving Fault Tolerance and Tackling Broker Failure in MQTT through Blockchain

Authors:

Abstract
MQTT is a widely used Publisher-Subscriber protocol in IoT and Edge Computing. Its lightweight, minimal overhead nature has aided real-time data exchange between the Publishers and the Subscribers. As of MQTT 5, the protocol has fault-tolerance and fault detection implemented through QoS Levels 1 and 2 in the form of ‘Retained Messages,’ ‘Persistent Sessions,’ and ‘LWT’ (‘Last Will’ and Testament’). Many researchers have dived deep into securing this protocol by using Blockchain, using multiple Fog and Mist Computing infrastructures, and they have accomplished faster, more efficient, and more secure implementations of the MQTT protocol. Often, the less explored scope of optimization is the fault tolerance of MQTT, which has its limitations. The current specification of MQTT allows the broker to only store one retained message per client ID, which becomes a limitation in the application use cases where the newly subscribed devices are supposed to get an array of data points instead of one. The current specification of MQTT does not implement fault tolerance on the broker end, which can disrupt the network on broker failure. The paper explores how we can use Blockchain Technology to overcome the limitations of ‘Retained Messages' in MQTT and improve the Dead Letter Exchanges in QoS levels 1 and 2 through Blockchain Technology. In addition, the paper explores and implements dynamic load balancing using Blockchain Naming Services to tackle broker failure in the MQTT protocol, which will allow brokers to be hosted under decentralized domain names on the Blockchain, monitored by a load balancer.