liveBook · Manning

MQTT

As explained in Secure APIs

MQTT is a lightweight publish-subscribe messaging protocol for asynchronous communication between machines.

MQTT is a lightweight publish-subscribe messaging protocol for asynchronous communication between machines. It is especially popular in Internet of Things (IoT) systems. section 9.1

In a service architecture, MQTT can connect an asynchronous backend API to an API gateway. The gateway translates that interface into a unified style, such as REST, so clients do not need to integrate with multiple API styles directly. section 9.1

MQTT behind an API gateway

An e-commerce backend might expose REST, GraphQL, gRPC, and asynchronous APIs using MQTT. An API gateway can translate these interfaces and present consumers with a consistent REST API. section 9.1

Figure 9.3 An API gateway can serve as a protocol and API style translation layer, helping us provide a unified API style to our consumers. Our backend might consist of GraphQL, REST, and asynchronous APIs, and we can expose them all as a REST interface through an API gateway.
figure

Use the diagram to see how an API gateway translates MQTT-based asynchronous APIs alongside REST, GraphQL, and gRPC. section 9.1

How Secure APIs covers it

How deep it goes
Defines MQTT and its gateway role but stops short of explaining message flows, topic design, or protocol internals.
Examples
Uses AWS IoT and an e-commerce backend combining MQTT with REST, GraphQL, and gRPC.
What you can do after
Evaluate how an API gateway can translate MQTT-based asynchronous APIs into a unified consumer-facing interface.
How it connects
Links MQTT with asynchronous APIs, API gateways, REST, GraphQL, gRPC, and Internet of Things systems.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Secure APIs. The section links point to the parts of the book it draws on.