MQTT 5.0 has made major changes based on MQTT 3.1.1 and is not backward compatible.
MQTT 5.0 supports many new features. EMQ X Broker supports MQTT 5.0 protocol from version 3.0. It is the first broker in the open source community to support the protocol specification and is fully compatible with MQTT V3.1 and V3.1.1 protocols.
Support user-defined attributes and transmission of additional custom information to expand more application scenarios.
Reduce the overhead of MQTT messages by shortening the topic name to a small integer.
Split the cleanup session flag into a new start flag and the session expiration interval can be modified when disconnected.
Allow the client and server to specify the number of outstanding reliable messages (QoS> 0) respectively.
Allows messages to be published with an expiration interval.
Allow the client and server to individually specify the maximum message lengths they support.
All response packets contain reason codes so that the caller can determine whether the requested function was successful.
Inform the client the feature list supported by the server to avoid the client using unsupported features.
Designed for problem location.
Provide a mechanism to enable challenge/response style authentication including mutual authentication.
The server is allowed to send a DISCONNECT message to indicate why the connection was closed.
Provide subscription options that are primarily used to define applications allowing message bridging.
Allows to specify payload format (binary, text) and MIME-style content types when publishing messages.
Provide the ability to delay the sending of the specified will message after the connection is interrupted.
Specify the MQTT request / response mode, provide the response topic and compare data attributes, and control the response message to be routed back to the request publisher.
Allow the server to specify the keep-alive values it wants the client to use.
Implemented in v3.1.1, adding support for shared subscriptions to allow load balancing for multiple subscription consumers.
If the server has assigned a client identifier, this client identifier is returned to the client.
Allows to specify a digital subscription identifier in the subscription packet and returns this identifier when the message is distributed.
Allows the server to specify a standby server.
Four years after the MQTT 3.1.1 has been released and became the OASIS standard, MQTT 5.0 was released, which is a significant improvement and upgrade.View
MQTT 5.0 Clean Start and Session Expiry Interval not only solve the legacy problems of Clean Session, but also extend the usage scenarios of the client.View
MQTT v3.1.1 protocol has only 10 return codes. These return codes can represent little meaning, and the same return code value can have different meanings in different messages.View
Payload Format Indicators and Content Type are two new properties introduced in MQTT 5.0.View
MQTT 5.0 adds the Response Topic, and defines the interaction process for Request Response. This article will introduce this feature in an easy-to-understand way.View
Shared subscription is a new feature introduced by MQTT 5.0 protocol, which is equivalent to the load balancing function of subscribers.View
MQTT 5.0 brings many new features, this article will introduce the use of subscription identifier and subscription options, in an easy-to-understand way.View
MQTT 5.0 brings many new features, this article will give an introduction to the use of the new feature "flow control" in an easy-to-understand way.View
MQTT 5.0 adds a new feature enhanced authentication, which includes query/response style authentication can implement bi-directional authentication of the client and broker.View