New

Introducing Free Tier: Get Started with Cedalo MQTT Platform |Get Started

Back to Blog

Message Broker: How Does It Work and When Does It Pay Off?

Philip Ackermann
Philip Ackermann Published September 8, 2026 12 min read
MQTT basics
Message Broker: How Does It Work and When Does It Pay Off?

Distributed systems can become vulnerable when services communicate directly with one another: as systems grow in size, tight coupling, cascading failures, and point-to-point connections that are difficult to modify often arise. A message broker is a common architectural approach to addressing these issues. It enables decoupled communication, supports flexible routing and delivery, and helps distributed systems remain more resilient even as requirements change.

Message Broker: key takeaways

  • A message broker decouples data producers from consumers by managing routing, persistence, and delivery between distributed systems.
  • Message brokers use two core patterns: Publish/Subscribe (all matching subscribers receive the message) and Point-to-Point (exactly one recipient consumes from a queue).
  • MQTT dominates in IIoT and edge environments, AMQP in transactional enterprise systems, and Kafka in high-throughput event streaming.
  • Pro Mosquitto extends Eclipse Mosquitto with clustering, automated failover, and RBAC, while the Cedalo MQTT Platform manages these Mosquitto deployments and adds integrations for Kafka, Azure Event Hubs, HTTP, SQL/NoSQL, Prometheus, and InfluxDB.

What is a message broker?

A message broker is a server-side middleware component that accepts messages from producers, applies routing logic, and delivers them to the appropriate consumers. It operates independently of both sides, so producers never need to know who processes their data, and consumers never need to know where the data originates.

This decoupling separates the act of sending from the act of receiving, both in time and in topology. A producer publishes a message and moves on. The broker handles persistence, routing, and delivery.

Three common functions appear in message broker architectures:

  • Routing: The broker determines which consumer or queue receives a given message, based on topics, routing keys, or header attributes.
  • Persistence: Depending on the protocol, broker, and configuration, messages can survive producer disconnects and consumer downtime until delivery succeeds or retention limits are reached.
  • Transformation: Some brokers or connected integration layers convert message formats or enrich payloads before forwarding, bridging protocol or schema differences between systems. In Pro Mosquitto, for example, Streams can capture, persist, and process MQTT data inside the broker.

Message broker vs. message queue broker

These terms describe related but distinct concepts. A message queue broker implements the Point-to-Point pattern: each message sits in a queue and gets consumed by exactly one recipient. A message broker is the broader category, encompassing both queue-based and topic-based (Publish/Subscribe) delivery models. Every message queue broker is a message broker, but not every message broker operates exclusively with queues.

Point-to-point integration wires every producer directly to every consumer, while broker-mediated integration routes all messages through a central message broker that decouples both sides
Figure 1: Point-to-point integration versus broker-mediated decoupling

How does a message broker work? Architecture explained

A message broker receives a message, evaluates its routing metadata, places it in the appropriate queue or topic, and delivers it to matching consumers. That sequence looks simple on the surface. The architecture underneath it determines whether a system holds up under load, partial failures, and evolving requirements.

Publish/Subscribe vs. Point-to-Point: which pattern fits your architecture?

The two foundational patterns in message broker architecture differ in how many consumers receive each message and whether delivery is targeted or broadcast.

CriterionPublish/SubscribePoint-to-Point (message queue)
Delivery targetAll matching subscribersExactly one consumer
Consumer awarenessConsumers subscribe independentlyConsumer polls or receives from a named queue
Typical use caseTelemetry distribution, event broadcastingTask processing, work distribution
Scalability modelFan out across many recipientsHorizontal scaling of workers
Example protocolMQTT, Apache KafkaAMQP, JMS

Pub/Sub fits scenarios where the same data needs to reach multiple independent systems simultaneously, for example, a temperature reading from a production line that feeds a dashboard, an analytics pipeline, and an alerting service at the same time. Point-to-Point fits task queues where each unit of work must be processed exactly once by one worker, such as an order processing system.

Many production architectures combine both. The broker accepts data via a topic and distributes it to specific queues for downstream processing.

How does message routing work inside a broker?

Routing logic is where the concrete differences between broker implementations become visible. Three approaches dominate in practice:

  • In MQTT, the broker evaluates hierarchical topic strings such as factory/line1/machine4/temperature against all active subscriptions. Wildcards (+ for a single level, # for all subsequent levels) allow flexible filtering without changing the publisher’s configuration. String matching keeps routing fast and resource-efficient at scale.
  • In AMQP, messages pass through an exchange layer before reaching a queue. The broker evaluates routing keys and binding patterns to direct each message into one or more queues. Exchange types (Direct, Fanout, Topic, Headers) give architects control over distribution logic at the broker level without touching message payloads.
  • In Apache Kafka, messages land in partitioned topics. Each partition is consumed by exactly one member of a consumer group, while multiple groups can consume the same partition independently. This model optimizes for high-throughput, ordered, durable streaming rather than low-latency device communication.

Delivery guarantees and acknowledgements

Many enterprise messaging systems support configurable delivery guarantees, although the exact semantics depend on the protocol, product, and configuration:

  • At most once: The broker sends the message without waiting for confirmation. This is the fastest option, but failed delivery is not retried.
  • At least once: The consumer confirms receipt. If confirmation does not arrive in time, the broker or client may retransmit, which means duplicate delivery is possible.
  • Exactly once: In some protocols and products, broker and client coordinate through additional acknowledgement or transaction steps to minimize both loss and duplication.

Dead Letter Queues (DLQs) capture messages that cannot be delivered after repeated attempts, preventing message loss and giving engineers a traceable record of failures.

Message broker examples across protocols and technologies

The choice of protocol shapes the entire message broker architecture. No single protocol dominates across all deployment scenarios. The following comparison covers the three most relevant options in industrial and enterprise contexts.

Technology / ProtocolPatternOverheadStrengthsTypical use
MQTTPub/SubVery lowLow bandwidth, device scalability, persistent sessionsIIoT, edge, machine telemetry
AMQPQueue + Pub/SubMediumTransactional delivery, complex routing, enterprise integrationERP, B2B, financial systems
Apache KafkaPub/Sub (log-based)Low-to-medium at scaleHigh throughput, replay, durable streamingEvent streaming, data pipelines

MQTT as a message broker protocol for industrial IoT

MQTT’s minimal binary protocol makes it the dominant choice wherever constrained devices communicate over low-bandwidth or intermittent connections. The broker handles session management natively: retained messages, LWT notifications, and automatic reconnection without any application-level implementation.

Eclipse Mosquitto, the open-source MQTT broker that Pro Mosquitto builds on, is widely deployed across IoT and industrial environments. The MQTT specification governs QoS levels, session persistence, and retained messages across all compliant implementations. For IoT infrastructures that need to grow beyond a single node, Pro Mosquitto adds clustering and high availability, and the Cedalo MQTT Platform provides the central management layer to operate it.

Ready to move your MQTT setup beyond a single node?

Get clustering, high availability, and centralized management on the most trusted open-source MQTT foundation worldwide.

AMQP and Apache Kafka: when does enterprise messaging require more?

AMQP adds transactional guarantees, persistent queues, and granular exchange-based routing to the message broker model. It suits scenarios where financial or operational consequences follow from duplicate or missed delivery. A detailed protocol comparison is available in the AMQP Protocol Guide.

Apache Kafka addresses a different problem: high-throughput event streaming with durable storage and replayability. It does not replace a device-facing message broker. It extends the backend. A detailed side-by-side analysis of where each technology fits appears in the MQTT vs. Kafka comparison.

In practice, many industrial architectures combine MQTT at the edge for device communication with Kafka or AMQP in the backend for analytics, ERP integration, and event replay. The MQTT broker acts as the ingestion layer; the backend system handles durable processing.

What are the real-world use cases for a message broker?

The concrete value of a message broker shows up where direct system-to-system integration fails under load or operational complexity.

Industrial IoT and smart manufacturing

Sensors, PLCs, and gateways on a production line generate continuous streams of telemetry. A message broker receives that data, routes it by topic to monitoring dashboards, MES systems, and cloud analytics platforms, and keeps each system independent of the others. When a new consumer needs access to production data, it subscribes to the relevant topic without requiring changes to the producers or the broker configuration.

This also resolves the data silo problem between OT and IT. The broker creates a shared data layer that both sides read from, rather than maintaining point-to-point connections between every machine and every enterprise system. The IoT integration overview on the Cedalo blog covers how this layer gets structured in practice.

Microservices architectures

In distributed software systems, services that communicate directly over HTTP create tight coupling. If one service goes down, its callers fail. A message broker decouples those services: the calling service publishes to a queue and continues. The downstream service processes the message when it recovers. This pattern improves fault tolerance without requiring synchronous availability of every component.

Logistics and supply chain

Event-driven tracking systems publish state changes (shipment dispatched, checkpoint passed, delivery confirmed) to a message broker. Multiple downstream systems, from warehouse management to customer notification services, consume those events independently and at their own pace. No polling, no repeated HTTP requests, no tight dependency between the tracking source and its consumers.

Energy and smart grid

Grid components and smart meters publish status signals and measurement data at high frequency. A message broker distributes that data to monitoring platforms, billing systems, and predictive algorithms without the data source needing to address each consumer directly. The broker absorbs burst traffic and smooths delivery to downstream systems with different processing speeds.

Message broker example in practice

A factory sensor publishes spindle RPM data to factory/line2/spindle/rpm. The MQTT broker routes that data simultaneously to a dashboard, a time-series database, and a predictive maintenance service. When the maintenance team adds a new analytics tool, it subscribes to the same topic. Nothing else changes.

When does a message broker service make sense for your project?

A message broker adds architectural value under specific conditions. Direct API calls or point-to-point integrations work fine at small scale and low complexity. The calculus shifts when the following factors appear.

Ask these five questions before committing to a broker:

  1. How many data sources and consumers does the architecture involve? In fully meshed point-to-point architectures, integration complexity can grow quadratically with the number of participants. A broker often reduces that complexity by centralizing routing and decoupling producers from consumers.
  2. Do consumers need to be available when producers send? If not, the broker must persist in sending messages and guarantee delivery after consumer recovery.
  3. Does the same data need to reach multiple independent systems? Pub/Sub is the correct model. Duplicating publish logic in the producer creates fragile, hard-to-maintain code.
  4. What delivery guarantee does the use case require? At-most-once may be acceptable for high-frequency telemetry. For control commands or financial transactions, stronger delivery semantics may be required, depending on the protocol, product, and end-to-end system design.
  5. Who manages the broker infrastructure? A message broker service introduces operational responsibility. That cost needs to be weighed against the complexity of the alternative.

If several of those questions point toward the broker model, the architectural overhead often becomes justified. If only one applies, a simpler integration pattern may still be sufficient.

Message broker architecture: from open source to enterprise

Deploying a message broker falls into three operational models, each with a different profile of control, responsibility, and capability.

ModelControlOperational effortTypical fit
Self-hosted open sourceFullHighPrototyping, development, small teams
Self-hosted enterpriseFullMediumProduction, regulated environments
Managed cloud serviceLimitedLowCloud-native apps, rapid onboarding

What distinguishes an enterprise message broker from a standard setup?

A basic open-source broker handles core messaging reliably. In production, features like clustering, failover, centralized management, integrations, and advanced security often require additional components or a managed platform.

FeatureEclipse Mosquitto (OSS)Pro Mosquitto
ClusteringNot includedYes, automated
High availability / failoverNot includedYes, stateful
Role-based access controlYes, via Dynamic Security (no LDAP or JWT)Granular RBAC with LDAP and JWT integration
TLS + mTLSManual configurationCentralized certificate management
Management UINot includedFull monitoring, configuration, and audit capabilities
IntegrationsMQTT bridge onlyDocumented integrations and bridges for Kafka, Azure Event Hubs, Google Pub/Sub, Amazon Redshift, HTTP, SQL/NoSQL, Prometheus, and InfluxDB
Audit trailsNoYes
Enterprise supportCommunity supportSLA-backed support

Is a message broker the right architecture for your project?

A message broker decouples producers from consumers, removes point-to-point dependencies, and gives distributed systems the routing, persistence, and delivery guarantees they need to scale. The architecture often pays off once multiple systems need to exchange data reliably and asynchronously.

Your advantages with Cedalo:

  • Enterprise-grade MQTT on the world’s most widely deployed open-source broker foundation.
  • Clustering and automated failover for 24/7 production environments.
  • Centralized management, RBAC, and audit trails for security and compliance.
  • Native integrations to Kafka, AWS, Azure, and major databases.

Take your message broker infrastructure to production grade

Pro Mosquitto adds clustering, high availability, and enterprise security to Eclipse Mosquitto, and the Cedalo MQTT Platform manages your Mosquitto deployments centrally, without changing your existing setup.

Message broker: frequently asked questions

How does a message broker handle message loss?

A message broker prevents data loss through persistence mechanisms: messages are written to disk and held in queues until the consumer confirms successful delivery. Delivery guarantees range from at-most-once to exactly-once, depending on the configured QoS level or acknowledgement protocol.

What happens to messages when a consumer is offline?

Depending on the protocol and broker configuration, messages may be queued for later delivery, and the latest retained message for a topic may remain available when the consumer reconnects.

Can a message broker connect OT and IT systems?

A message broker acts as a neutral data layer between operational technology (OT) and IT systems by standardizing communication through topics and queues. It removes the need for direct machine-to-application interfaces and allows SCADA systems, ERP platforms, and cloud services to consume the same data stream independently.

How does Cedalo differ from a standard Eclipse Mosquitto broker?

Pro Mosquitto extends Eclipse Mosquitto with clustering, high availability, and role-based access control, and the Cedalo Management Center adds centralized management that a standard Eclipse Mosquitto installation does not include. This makes Pro Mosquitto with the Cedalo MQTT Platform suitable for production environments where uptime, security, and multi-broker management are non-negotiable operational requirements.

At what point does a message broker become a single point of failure?

A single broker instance without redundancy becomes a critical failure point the moment it goes down. Clustered broker setups with automated failover significantly reduce this risk by distributing sessions and state across multiple nodes, so traffic can continue with less disruption if one node fails.

How does Cedalo support message broker deployments across multiple sites?

The Cedalo MQTT Platform supports distributed deployments across plants and locations from a single management interface, with centralized security policies and broker configuration management across multiple nodes. This allows industrial organizations to scale their messaging infrastructure site by site with more consistent operations and less configuration drift.

About the author

Philip Ackermann
Philip Ackermann

Chief Technology Officer (CTO) at Cedalo

Philip Ackermann is the Chief Technology Officer (CTO) at Cedalo, bringing over 20 years of software development experience to the team. During his 11 years at the Fraunhofer Institute, specializing in Web Compliance and IoT technologies, he focused on software engineering, software architecture, and product development.

In addition to that, Philip is a published author, having written five books on software development, covering topics such as Java, JavaScript, Node.js, and Fullstack web development. Two of these books have been translated into English, broadening their global impact and enriching the international software development community

View all articles by Philip Ackermann

Related Posts

MQTT Client: How to Choose, Configure, and Operate the Right Tool for Your Environment

MQTT Client: How to Choose, Configure, and Operate the Right Tool for Your Environment

Most MQTT client problems come from configuration, not the protocol: misconfigured TLS, wrong QoS assumptions, and clients that pass testing but collapse under production load. This guide explains what an MQTT client does, how the four client categories map to development and deployment phases, and how to configure client ID, sessions, Keep-Alive, QoS, TLS, and authentication correctly. It also covers the most common client failures, what changes when clients move into production, and how the broker layer decides whether your setup holds at scale.

MQTT basics
AMQP Guide: Architecture and Implementation of the Enterprise Messaging Standard

AMQP Guide: Architecture and Implementation of the Enterprise Messaging Standard

AMQP is a standardized, binary messaging protocol for reliable, transactional data exchange across distributed enterprise systems. This guide explains the broker model (exchanges, queues, bindings), the four exchange types, message lifecycle, reliability and flow control, the difference between AMQP 0-9-1 and 1.0, and how AMQP fits alongside MQTT in industrial architectures.

Protocols
AMQP vs. MQTT: Technical Comparison for Enterprise Messaging and IIoT

AMQP vs. MQTT: Technical Comparison for Enterprise Messaging and IIoT

AMQP and MQTT solve different problems: MQTT delivers lightweight publish/subscribe for IIoT and edge telemetry, while AMQP adds transactional integrity and durable queuing for enterprise backends. This comparison covers messaging models, routing, overhead, reliability, and scalability, and shows how a hybrid MQTT-AMQP architecture combines both.

Protocols