Preparing a public MQTT broker service
Recall the previous chapter, Chapter 10, Handling Sensor Data on the Raspberry Pi. We sent the data of the temperature/humidity sensor, which was connected to the edge device (Raspberry Pi), to the cloud and confirmed that the data could be observed on the cloud side.
In the previous chapter, we checked how to operate an MQTT broker using a service called Mosquitto. This was in order to focus on sending data from edge devices to an MQTT broker.
However, this was a mechanism where everything was done locally on the Raspberry Pi. Essentially, when trying to implement an IoT mechanism, MQTT brokers should be in a public location and accessible from anywhere via the internet.
It is possible to host your own Mosquitto MQTT broker in the public cloud, but that adds some extra complexity in terms of setting up and maintaining it. There are a number of public MQTT services available that can make it easier to get started.
In this chapter...