Skip to content

MQTT Brokers

  • In this documentation, I will be taking you through what is an MQTT Broker and show you the types OVES has.

Introduction

  • MQTT (Message Queuing Telemetry Transport) broker is a server that enables communication between devices and applications using the MQTT protocol. MQTT is a lightweight messaging protocol designed for IoT (Internet of Things) and mobile applications that require low bandwidth and low power consumption.
  • The MQTT broker acts as a central point for receiving and distributing messages between MQTT clients, which can be devices, sensors, or applications that publish or subscribe to the broker. The broker is responsible for routing messages between the publisher and the subscriber, ensuring that messages are delivered to the correct recipient.
  • At OVES we have different types of MQTT brokers that we use to perform different functionalities.
  • Below are the types of MQTT Brokers used at OVES:

    • Central/Protected Broker
    • Factory Broker
    • Client Broker
    • Edge/Hub Brokers

    NB: You can also view the below Architecture of the MQTT Brokers

    Central Broker/protected Broker

    • Also known as the Protected Broker is the main broker of OVES. It runs on the url: mqtt-2.omnivoltaic.com:8883.
    • The Central Broker is protected using a password and TLS. For one to be able to access the Central Broker, they must have TLS certificates for someone or another broker to communicate with it and have an account on ERM either as a distributor, admin, or any OVES role user.
    • This MQTT Broker is normally used to Authorize only the allowed users and clients of OVES.
    • This MQTT Broker also has a Password file. This file is generated by our GraphQL API endpoint for getAllDistributor. It maps the user and the MQTT password for specific distributors. That file is then used to only Authorize the specific distributors who’s credentials are on the password.txt file
    • This MQTT Broker also has an ACL file which is a list of permissions that specify which MQTT topics a user is allowed to subscribe to or publish to.

    Factory Broker

    • A special kind of MQTT Broker which is used by all the devices from the factory. All those devices get embedded with the Factory Broker before being assigned to a client.
    • The Factory Broker bridges from the Central Broker and it gets to the user (Admin). That user is able to access all device topics as it is a special broker.
    • The Factory Broker runs on the url: mqtt-factory.omnivoltaic.com:18883

    Client Broker

    • The Client MQTT Broker is the broker that belongs to a single Distributor. This MQTT Broker bridges from the Central Broker. It uses a recognized user and password to be able to bridge to the Central Broker.
    • This broker is only allowed to view topics that are set on the ACL file of the central broker.
    • The URL of the Client Broker varies depending on the client. Mostly we have the Client Broker use a subdomain that’s specific to the client.

    Edge/Hub Broker

    OmniMQTTBridgingArchitecture.svg

    • The Edge Broker is the broker that is used by all physical devices that are owned by a Client.
    • The Edge Broker bridges from the Client Broker. The Edge Brokers will be able to access all the devices belonging to the Client Broker it is bridging from.