Understanding MQTT Print

  • internetthings, internet, guide, howto, solution, zillionkinghost, hosting, support
  • 0

The dominant IoT messaging protocol.

WHAT IT IS

A lightweight publish-and-subscribe protocol designed for constrained devices and unreliable networks.

WHAT PUBLISH AND SUBSCRIBE MEANS

Devices publish to topics; interested parties subscribe to them, without knowing each other.

WHAT A BROKER DOES

Receives published messages and distributes them to subscribers.

WHY THAT DECOUPLING MATTERS

Devices and applications can be added or removed without either knowing.

WHAT A TOPIC IS

A hierarchical string identifying a channel.

WHAT GOOD TOPIC DESIGN LOOKS LIKE

A consistent hierarchy: type, identifier, then measurement.

WHY STRUCTURE MATTERS

Subscribers use wildcards, and an inconsistent hierarchy makes that impossible.

WHAT TO NEVER PUT IN A TOPIC

Values that change, such as readings.

WHY

Each distinct topic is a separate channel, and the broker retains them.

WHAT QUALITY OF SERVICE LEVELS PROVIDE

At most once, with no guarantee At least once, with possible duplicates Exactly once, with more overhead

WHAT TO USE

At least once, with idempotent handling, for most cases.

WHAT A RETAINED MESSAGE IS

The last message on a topic, delivered immediately to new subscribers.

WHAT IT SUITS

Current state, so a subscriber need not wait for the next update.


Was this answer helpful?
Back

Are you happy with your experience? Leave us a review on Trustpilot.


Trustpilot