Preface

Many MQTT projects and Internet of Things services provide online public MQTT server , users can directly use it for MQTT learning, testing, prototyping and even small-scale use, without the need for self-deployment, which is convenient and fast, saving time and energy cost.

However, due to different geographic locations, network environments, and server loads, the stability and message transmission delay of each public server are also different. Although almost all service providers state that they are not responsible for the stability and security of their free services, users need to consider these factors when using them.

To this end, this article has compiled some of the more popular free online MQTT servers, and evaluated and compared them through accessibility, network delay, small-scale performance testing, and actual message transmission delay, etc., hoping to provide a reference for your choice .

Popular online public MQTT servers

This article selects the following popular online public MQTT servers:

nameBroker addressTCPTLSWebSocket
EMQ Xbroker.emqx.io188388838083,8084
EMQ X (domestic)broker-cn.emqx.io188388838083,8084
Eclipsemqtt.eclipseprojects.io1883888380, 443
Mosquittotest.mosquitto.org18838883, 888480
HiveMQbroker.hivemq.com1883N/A8000

EMQ X

Free online MQTT 5 server, provided by EMQ X Cloud . In order to optimize the access speed of domestic users, two overseas and domestic access points are provided. EMQ X is deployed in the Oregon region of AWS, and EMQ X (domestic) is deployed in the Tencent Cloud Shanghai region. There is a stable network channel for domestic access.

Both access points are the EMQ X cluster composed of 2 nodes. Later, it can automatically expand more nodes according to the actual access volume and load. According to the background display, the server is based on EMQ X Enterprise Edition 4.2.6 version, and the current running time is 128 days.

For details, please visit the EMQ official website page: Free online MQTT 5 server .

Note: EMQ X and EMQ X (domestic) two access points do not communicate with each other.

Eclipse

The free online MQTT server provided by Eclipse IoT, the resolved IP shows that it is deployed in Azure, USA, Virginia. It’s worth mentioning that the server’s access address has always been mqtt.eclipse.org , and it’s changed to the current access address for some reason. At the time of writing this article, I used the old address and failed to access the server. I thought the server had stopped, and finally accessed the original through HTTP. It was discovered that the 301 permanent redirection had been done when the access point was reached.

According to the $SYS/# system subject query, the server is based on the Mosquitto 2.0.12 version, and the current running time is 71227 seconds. It is suspected that the service was restarted a day ago.

Related introduction: https://mqtt.eclipseprojects.io/

Mosquitto

A free online MQTT server provided by the Mosquitto community. The resolved IP shows that it is deployed in the OVH French Roubaix region. In the test, it was found that the network delay of the access point is relatively high under normal conditions, but fortunately the packet loss rate is relatively low, and connection failures may occur during certain periods.

According to the $SYS/# system subject query, the server is based on the Mosquitto 2.0.12 version, and the current running time is 28,519 seconds. It is suspected that the service has been restarted in one day.

Related introduction: https://test.mosquitto.org/

HiveMQ

The free online MQTT server provided by HiveMQ, the resolved IP shows that it is deployed in the Frankfurt region of AWS, Germany.

Because its $SYS/# system topic cannot be subscribed, it is impossible to know the type of Broker providing the service, the specific version, and the current running time.

Related introduction: http://www.mqtt-dashboard.com/

test environment

  • Network: Domestic and Yunnan Telecom Network
  • Operating system: macOS 10.15.7
Note: Due to different geographical locations, the network environment of different places will be different, which may lead to differences in the test results of this article.

Accessibility test

Test Results

In this session, the MQTT client tool-MQTT X was used to conduct an accessibility test, trying to establish a connection through the TCP 1883 port. After repeated testing, only the free services provided by Eclipse could not be accessed. The overall results are as follows:

nameBroker addressTCPAvailable
EMQ Xbroker.emqx.io1883YES
EMQ X (domestic)broker-cn.emqx.io1883YES
Eclipsemqtt.eclipseprojects.io1883NO
Mosquittotest.mosquitto.org1883YES
HiveMQbroker.hivemq.com1883YES

在线 mqtt 服务器可访问性测试

Test configuration file download

MQTT X has the connection import and export function. The following is the connection data used in the test in this article, which can be imported into MQTT X through data recovery.

MQTT X 配置文件导入

Domestic network delay test

Detect network connectivity and network delay through network access. Because some services have disabled the ICMP protocol, and the network conditions in various places are different, the WebSocket address is used here, with the help of the popular domestic speed measurement tool webmaster tool for HTTP speed measurement test:

nameHTTP address (click to test)WebSocket
EMQ Xhttp://broker.emqx.io:8083/mqtt8083
EMQ X (domestic)http://broker-cn.emqx.io:8083/mqtt8083
Eclipsehttp://mqtt.eclipseprojects.io/mqtt80
Mosquittohttp://test.mosquitto.org/mqtt80
HiveMQhttp://broker.hivemq.com:8000/mqtt8000

EMQ X 国内在线 MQTT 服务器

EMQ X 在线 MQTT 服务器

Mosquitto 在线 MQTT 服务器

HiveMQ 在线 MQTT 服务器

Small-scale performance test

Use the open source MQTT performance testing tool emqtt-bench to test to test whether the Pub Sub of the client has a rate limit.

For practical considerations , this round of testing is not to explore the upper limit of the rate of each access point, but to consider that each access point can meet the conventional intensity of use. The scenario designed in this round is to test the single client Sub/Pub message for 1000 msg/s for 1 minute, and the message size is 256 Bytes. Record whether each access point meets the standard and whether the speed is limited. The following figure shows the test architecture:

MQTT 服务器测试

After preparing emqtt-bench, each group of Sub Pub commands below can be executed in different windows:

nameBroker addressTCPPub meets the standardSub standard
EMQ Xbroker.emqx.io1883YESYES
EMQ X (domestic)broker-cn.emqx.io1883YESYES
Eclipsemqtt.eclipseprojects.io1883YESYES
Mosquittotest.mosquitto.org1883The rate fluctuates around 50 msg/sThe rate fluctuates between 0-50 msg/s
HiveMQbroker.hivemq.com1883YESThe rate is stable at about 50 msg/s
# EMQ X
## Sub
./emqtt_bench sub -t t/1 -c 1 -h broker.emqx.io
## Pub
./emqtt_bench pub -t t/1 -c 1 -h broker.emqx.io -I 1

# EMQ X CN
## Sub
./emqtt_bench sub -t t/1 -c 1 -h broker-cn.emqx.io
## Pub
./emqtt_bench pub -t t/1 -c 1 -h broker-cn.emqx.io -I 1

# Eclipse
## Sub
./emqtt_bench sub -t t/1 -c 1 -h mqtt.eclipseprojects.io
## Pub
./emqtt_bench pub -t t/1 -c 1 -h mqtt.eclipseprojects.io -I 1

# Mosquitto
## Sub
./emqtt_bench sub -t t/1 -c 1 -h test.mosquitto.org
## Pub
./emqtt_bench pub -t t/1 -c 1 -h test.mosquitto.org -I 1

# HiveMQ
## Sub
./emqtt_bench sub -t t/1 -c 1 -h broker.hivemq.com
## Pub
./emqtt_bench pub -t t/1 -c 1 -h broker.hivemq.com -I 1

Message actual transmission delay test

Purpose: Consider the time required for the message to go from the Pub end to the Sub end, sample and analyze the transmission stability and average time consumption.

Test steps: The client connects to the public server and publishes a time-stamped message every 5 seconds. After the subscriber receives the message, the current timestamp is subtracted from the timestamp in the message, and the message delay is calculated and recorded in the database. Sampling and analysis are performed after 30 minutes of statistics.

The test model is as follows:

MQTT 服务器消息传输延时测试模型

Test code: free-online-public-broker-test.js

Time delay history

MQTT 服务器消息传输延时测试

Average delay

nameBroker addressTCPAverage delay
EMQ Xbroker.emqx.io1883212 ms
EMQ X (domestic)broker-cn.emqx.io188352.6 ms
Eclipsemqtt.eclipseprojects.io1883261 ms
Mosquittotest.mosquitto.org1883874 ms
HiveMQbroker.hivemq.com1883574 ms

Summarize

In several tests, each free online MQTT server has reached a usable level as a whole, but there are still significant differences between the servers in specific indicators. Low rate limits, unstable network delays, and even some servers are suspected of having a scheduled restart mechanism. These stability and usability issues will bring a bad experience to users even in simple testing and prototyping.

The above content also proves to a certain extent that the relevant performance of the IoT platform is affected by the geographic location of the device. Therefore, the EMQ X free online MQTT service that provides nearby access points based on high-quality cloud service provider networks in overseas and domestic has certain advantages in comparison, and all aspects of test data are relatively leading.

We are also very pleased to see that more and more IoT devices from all over the world are connected to the online MQTT server provided by EMQ X. On average, thousands of messages are delivered per second. broker.emqx.io:1883 also appears in various open source projects and sample codes on GitHub ( https://github.com/search?q=broker.emqx.io&type=Code ). Domestic users can choose the broker-cn.emqx.io node that is optimized for domestic deployment.

Both domestic and overseas access point services of EMQ X online public server are provided by EMQ X Cloud . EMQ X Cloud is a fully managed cloud native MQTT messaging service provided by EMQ, supporting commercial-grade accessibility and stability guarantees. For business users, using EMQ X Cloud can quickly start projects at zero cost and implement MQTT device access in a simple and fast way. Later, it can be expanded as needed according to the business development, and at the same time, it can create access points around the world and enjoy the 7*24 technical support guarantee provided by the EMQ professional team.

Whether it is a personal or enterprise project, EMQ is committed to providing the most suitable MQTT messaging service for all kinds of users. If you have any comments or questions in the process of using EMQ X, please feel free to give feedback to our team.


EMQX
336 声望436 粉丝

EMQ(杭州映云科技有限公司)是一家开源物联网数据基础设施软件供应商,交付全球领先的开源 MQTT 消息服务器和流处理数据库,提供基于云原生+边缘计算技术的一站式解决方案,实现企业云边端实时数据连接、移动、...