Web Design

Your content goes here. Edit or remove this text inline.

Logo Design

Your content goes here. Edit or remove this text inline.

Web Development

Your content goes here. Edit or remove this text inline.

White Labeling

Your content goes here. Edit or remove this text inline.

VIEW ALL SERVICES 

Discussion – 

0

What message-oriented middleware is actually running under your queue?

Illustration of three message-oriented middleware decisions, each shown as two contrasting shapes: point-to-point versus publish-subscribe, broker-based versus brokerless, and AMQP versus MQTT

Do you know which message-oriented middleware is actually running underneath your event bus? A design review stalls on that exact question when nobody in the room can answer it: does the queue drop messages under load, duplicate them, or just slow down? Every stack now ships a queue, a broker, or an event bus by default. Fewer engineers can say why theirs behaves the way it does when a downstream consumer falls behind, or why a system built on the same category of tool as theirs fails in exactly the opposite direction.

Message-oriented middleware is basically the software layer that lets separate parts of a system exchange messages without talking to each other directly. It is a category, not a single product: a work queue, a publish-subscribe broker, and an event bus are all implementations of it, and two systems marketed under the same name can still inherit opposite failure modes.

A message moving through three message-oriented middleware decisions, each shown as two contrasting shapes: point-to-point versus publish-subscribe, broker-based versus brokerless, and AMQP versus MQTT

The first message-oriented middleware decision: point-to-point or publish-subscribe

The oldest distinction in message-oriented middleware is who owns the fan-out, the communication model, and it comes straight from Enterprise Integration Patterns by Gregor Hohpe and Bobby Woolf, still the reference vocabulary for this whole space over twenty years later.

A Point-to-Point Channel guarantees that only one receiver consumes any given message, even when several consumers are listening on the same channel at once. That guarantee is what makes it the right shape for a work queue: ten workers can pull from the same channel, and the channel itself, not any coordination code the team writes, ensures a job is not processed twice. Task queues, order processing, a publishing queue where only one worker should push a given article live, anything that reads like “do this exactly once” belongs here.

A Publish-Subscribe Channel does the opposite. It takes a single input and splits it into multiple output channels, one per subscriber, delivering a full copy of the message to each. Nobody polls a queue and races for the job; everybody who subscribed gets their own copy, independently. That is the shape for events: an order was placed, and the shipping service, the billing service, and the fraud model all need to know, none of them competing with the others for the privilege.

Confusing the two is not a cosmetic mistake. Build a fan-out notification system on a point-to-point channel and only one interested service will ever see the message; the others silently starve. Build a job queue on a publish-subscribe channel and every worker processes every job, quietly multiplying the work by the number of workers you added for scale.

Underneath either communication model, a message queue decides how it actually runs

Point-to-point and publish-subscribe describe who is allowed to receive a message, not how it physically moves between sender and receiver. Underneath either one, something still has to hold the message between the moment it is sent and the moment it is read: a message queue. What differs between implementations is the protocol governing how producers and consumers talk to that queue, and that protocol carries its own assumptions about the network underneath it.

AMQP was built for a broker to sit in the middle, with the protocol itself defining exchanges, queues, and routing as first-class concepts; it assumes a stable connection and a broker doing real work. MQTT was built for the opposite assumption: unreliable, low-bandwidth links and constrained devices, which is why it trades AMQP’s routing richness for a minimal, publish-subscribe-only model that survives a flaky connection. HTTP/2, used directly or as the transport under gRPC, assumes neither a broker nor a constrained device; it assumes two participants who can hold open a multiplexed connection and exchange calls with request-response semantics baked in.

Picking a protocol before the communication model is settled tends to produce systems where the wire format and the actual communication shape disagree: an HTTP/2 request-response call standing in for what is really a fire-and-forget event, or an MQTT publish-subscribe topic bent sideways to simulate a one-to-one job queue it was never built to guarantee.

Broker or brokerless: who owns durability and backpressure

The next decision sits one layer down: does a broker sit between sender and receiver, or do they talk directly?

Broker-based systems like Kafka and RabbitMQ put a durable, addressable intermediary between producer and consumer. The broker holds the message, tracks who has read what, and absorbs the difference in speed between a fast producer and a slow consumer. That absorption is the whole point: if the consumer stalls, messages queue up in the broker instead of piling up in the producer’s memory or getting dropped on the floor. The cost is that the broker becomes infrastructure in its own right, with its own durability guarantees, its own disk, its own operational surface to run and monitor.

Brokerless systems like ZeroMQ, or a direct RPC call over gRPC, remove that intermediary. The producer talks straight to the consumer, which usually means lower latency and one fewer service to operate. It also means the two ends now own backpressure themselves. If the consumer cannot keep up and there is no broker to absorb the difference, the producer either blocks, drops messages, or has to implement its own buffering, by hand, in application code that a broker would have handled for free.

Neither option is wrong. A broker earns its operational cost when producers and consumers run at different speeds, need to be decoupled in time, or need more than one consumer group reading the same stream. A brokerless call earns its simplicity when both ends are fast, tightly coupled, and already in the same failure domain, so there is nothing for a broker to decouple.

What Kafka solves that plain message-oriented middleware doesn’t

Kafka answers all three of the decisions above with one set of defaults, which is why it gets treated as a category of its own rather than just another broker. It is broker-based: a cluster of brokers holds every message durably on disk, so a slow consumer never forces the producer to block or drop anything. Its wire protocol is its own binary protocol over TCP, built for throughput rather than for the routing richness of AMQP or the low-bandwidth assumptions of MQTT. And its communication model sits between the two extremes covered above: a topic behaves like publish-subscribe across consumer groups, since every group gets its own full copy of the stream, but like point-to-point within a group, since partitions divide the work so each message is read once per group.

That combination, durable and replayable storage, one protocol tuned for volume, and a communication model that acts like a queue and a broadcast depending on which layer you look at, is what a plain queue or a plain pub-sub broker cannot offer on its own. The trade-off is operational: running that cluster, its partitions, and its replication is a heavier commitment than a single queue or a direct RPC call, and it solves a problem plenty of teams don’t actually have.

Four decisions, one series

None of this shows up in a product comparison page, because none of it is about the product. It is about which pieces of message-oriented middleware a team committed to, on purpose or by accident, before a single line of application code got written. The pattern decides your failure mode long before the protocol decides your throughput.

This is the first post in a short series. The communication model, message queue protocols, broker-based versus brokerless, and Kafka itself each get their own deep dive next, with the trade-offs worked through in more depth than a survey post can carry.

Which of these have you had to defend in a design review, and did the reviewer already know the trade-off?

Pastel Gbetoho

0 Comments

You May Also Like

What do message queue protocols actually guarantee?

A broker restart loses messages the team believed were guaranteed, because the protocol never promised to keep them. We test five message queue protocols against the six properties every message-oriented middleware is judged on, and show where the wire ends and the broker begins.