Internet of Things platform MQTT access capability assessment method

By using TSBS tools to generate timing data that complies with MQTT protocol, and combined with tools such as Flume and Prometheus to simulate and monitor the MQTT messaging process of the Internet of Things platform, the problem of not representative test data in the existing test methods is solved, and efficient and accurate MQTT protocol access capability evaluation is achieved, which significantly improves the testing accuracy and efficiency.

CN119603186APending Publication Date: 2025-03-11上海沄熹科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411563640.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-05
Publication Date
2025-03-11

AI Technical Summary

Technical Problem

When evaluating the access capability of the MQTT protocol of the existing testing methods, the generated test data is not representative, which can easily lead to duplicate timestamps or inaccurateness, and cannot truly reflect the performance in the actual production environment.

Method used

By using the TSBS tool to generate timing data that conforms to the MQTT protocol message format, and combined with the configuration and application of the Flume tool, the actual MQTT messaging process is simulated. At the same time, real-time performance monitoring is carried out through Prometheus, and the Grafana dashboard is used to visually display performance indicators and system status, combining performance indicator data and log data of the IoT platform for system performance analysis.

Benefits of technology

It realizes efficient and accurate testing of MQTT protocol access capabilities, significantly improves the accuracy of MQTT access capabilities evaluation of IoT platforms, and can more accurately evaluate the performance of the system in real scenarios, simplify the testing process, and improves testing efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119603186A_ABST
    Figure CN119603186A_ABST
Patent Text Reader

Abstract

The invention discloses an Internet of Things platform MQTT access capability assessment method, and relates to the technical field of Internet of Things. Comprising the steps of 1, using a TSBS tool to generate time sequence data conforming to an MQTT protocol message format and storing the time sequence data, 2, modifying a Flume configuration file: configuring a batch processing size batchSize, an MQTT theme topic, host information and a spoolDir catalogue, 3, starting Flume to read the time sequence data generated by the TSBS, simulating a transmission process of the time sequence data into an actual MQTT message transmission process, and 4, starting the Flume to read the time sequence data generated by the TSBS. And 4, monitoring performance indexes of the Internet of Things platform system through Prometheus and collecting performance index data in real time, visually displaying the performance indexes and the system state through a Grafana instrument panel, and after Flume operation is completed, performing Internet of Things platform system performance analysis in combination with the performance index data and log data of the Internet of Things platform.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention discloses an MQTT access capability evaluation method for an Internet of Things platform, and relates to the technical field of the Internet of Things. Background Art

[0002] In the field of IoT technology, devices exchange data with cloud platforms through network protocols. IoT devices usually need to report data to a central system or cloud platform for real-time monitoring and data analysis.

[0003] As a lightweight message transmission protocol, MQTT has been widely used in IoT applications. With the rapid increase in the number of IoT devices and the dramatic increase in data volume, it is necessary to evaluate the MQTT protocol access capabilities of IoT platforms. Existing testing methods usually use JMeter, but the test data generated by these tools has limitations and is not representative. It is easy to cause duplicate or inaccurate timestamps, which cannot truly reflect the performance in the actual production environment. Summary of the invention

[0004] In view of the problems of the prior art, the present invention provides a method for evaluating the MQTT access capability of an Internet of Things platform, which can realize efficient and accurate testing of the MQTT protocol access capability, and can significantly improve the evaluation accuracy of the MQTT access capability of the Internet of Things platform, and has important application value.

[0005] The specific scheme proposed by the present invention is:

[0006] The present invention provides an MQTT access capability evaluation method for an Internet of Things platform, comprising:

[0007] Step 1: Use the TSBS tool to generate and save time series data that conforms to the MQTT protocol message format.

[0008] Step 2: Modify the Flume configuration file: configure the batch processing size batchSize, MQTT topic topic, host information, and spoolDir directory.

[0009] Step 3: Start Flume to read the time series data generated by TSBS and send the time series data to MemoryChannel. Establish a connection with the MQTT Broker of the IoT platform through MQTT Sink. Read the time series data from MemoryChannel through MQTT Sink and send the time series data to the specified MQTT topic. Receive the time series data through MQTT Broker and forward it to the client that has subscribed to the corresponding topic. Simulate the time series data transmission process as the actual MQTT message transmission process.

[0010] Step 4: Use Prometheus to monitor the performance indicators of the IoT platform system and collect performance indicator data in real time. Use the Grafana dashboard to visualize the performance indicators and system status. After Flume is completed, combine the performance indicator data with the log data of the IoT platform to analyze the performance of the IoT platform system.

[0011] Furthermore, in step 1 of the method for evaluating the MQTT access capability of an IoT platform, a CPU-only scenario is selected to use the TSBS tool to generate time series data that conforms to the MQTT protocol message format, and the generated time series data is saved in a text file for subsequent Flume to read and forward the time series data.

[0012] Furthermore, in step 4 of the method for evaluating the access capability of an Internet of Things platform MQTT, performance indicator data is collected in real time through Prometheus, and the performance indicator data includes system CPU usage, memory usage, throughput, delay time and error rate.

[0013] Furthermore, in step 4 of the method for evaluating the MQTT access capability of an Internet of Things platform, the operating data during the test is collected as log data through the log system of the Internet of Things platform.

[0014] The present invention also provides an MQTT access capability evaluation device for an Internet of Things platform, comprising a data generation module, a data reading management module and a monitoring and analysis module.

[0015] The data generation module uses the TSBS tool to generate and save time series data that conforms to the MQTT protocol message format.

[0016] The data reading management module modifies the Flume configuration file: configure the batch processing size batchSize, MQTT topic topic, host information, and spoolDir directory.

[0017] The data reading management module starts Flume to read the time series data generated by TSBS, and sends the time series data to the Memory Channel. It establishes a connection with the MQTT Broker of the IoT platform through the MQTT Sink, reads the time series data from the Memory Channel through the MQTT Sink, and sends the time series data to the specified MQTT topic. It receives the time series data through the MQTT Broker and forwards the time series data to the client that has subscribed to the corresponding topic, simulating the time series data transmission process as the actual MQTT message transmission process.

[0018] The monitoring and analysis module monitors the performance indicators of the IoT platform system through Prometheus and collects performance indicator data in real time. It visualizes the performance indicators and system status through the Grafana dashboard. After Flume runs, it combines the performance indicator data and the log data of the IoT platform to perform IoT platform system performance analysis.

[0019] Furthermore, the data generation module of the IoT platform MQTT access capability evaluation device selects the CPU-only scenario and uses the TSBS tool to generate time series data that conforms to the MQTT protocol message format, and saves the generated time series data to a text file for subsequent Flume to read and forward the time series data.

[0020] Furthermore, the monitoring and analysis module of the MQTT access capability evaluation device for an Internet of Things platform collects performance indicator data in real time through Prometheus, and the performance indicator data includes system CPU usage, memory occupancy, throughput, delay time and error rate.

[0021] Furthermore, the monitoring and analysis module of the MQTT access capability evaluation device for an Internet of Things platform collects the operating data during the test as log data through the log system of the Internet of Things platform.

[0022] The benefits of the method of the present invention are:

[0023] 1. The TSBS tool is used to generate time series data that conforms to the MQTT protocol message format, ensuring the authenticity and representativeness of the test data. The data reporting situation of actual IoT devices is simulated, so that the performance of the system in real scenarios can be more accurately evaluated.

[0024] 2. The configuration and application of Flume tools make data flow processing more efficient and reliable. Data can be transmitted from the generation source to the MQTT Broker in real time, and flow control is implemented to ensure the real-time and integrity of the data.

[0025] 3. Real-time performance monitoring combined with Prometheus can comprehensively track the system's operating status and performance indicators. Through the visual display of the Grafana dashboard, users can intuitively see the performance of the system under different loads and discover potential problems and bottlenecks in a timely manner. This monitoring mechanism not only provides real-time feedback on system operation, but also provides detailed data support for subsequent performance optimization.

[0026] 4. Through automated tools and configurable methods, the process of MQTT protocol access capability testing is simplified and the efficiency of testing is improved. Through systematic testing solutions, manual intervention and errors are reduced, ensuring the accuracy and reliability of test results.

[0027] In summary, the present invention can accurately simulate the actual MQTT message transmission process through advanced data generation and stream processing technology, a comprehensive monitoring mechanism, and a precise evaluation method, improve the efficiency and accuracy of the test, identify the performance bottlenecks and optimization space of the system, and provide an effective solution for the performance testing and optimization of the Internet of Things system, thereby improving the overall performance and stability of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 It is a schematic diagram of the application framework of the method of the present invention. DETAILED DESCRIPTION

[0029] TSBS is a tool for time series data generation and performance testing that can generate real data sets under various load scenarios.

[0030] Flume is a distributed, reliable system for efficiently collecting, aggregating, and transmitting large amounts of data. Combining these two tools allows for more accurate simulation and testing of the MQTT protocol performance of IoT platforms, avoiding data inaccuracies and duplicate timestamps that occur in testing methods.

[0031] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments so that those skilled in the art can better understand the present invention and implement it, but the embodiments are not intended to limit the present invention.

[0032] Example 1

[0033] The present invention provides an MQTT access capability evaluation method for an Internet of Things platform, comprising:

[0034] Step 1: Use the TSBS tool to generate and save time series data that conforms to the MQTT protocol message format. Use the TSBS tool to generate time series data that conforms to the MQTT protocol message format. Select the CPU-only scenario to ensure the efficiency and accuracy of the test data. Save the generated time series data to a text file for subsequent Flume to read and forward the time series data.

[0035] Step 2: Modify the Flume configuration file: configure the batch processing size batchSize, MQTT topic topic, host information such as the target server IP address and port number, and the spoolDir directory where the TSBS data files are located to ensure that data can be transmitted efficiently and accurately.

[0036] Step 3: Start Flume to read the time series data generated by TSBS and send the time series data to MemoryChannel. Establish a connection with the MQTT Broker of the IoT platform through MQTT Sink. Read the time series data from MemoryChannel through MQTT Sink and send the time series data to the specified MQTT topic. Receive the time series data through MQTT Broker and forward it to the client that has subscribed to the corresponding topic. Simulate the time series data transmission process as the actual MQTT message transmission process.

[0037] Step 4: Use Prometheus to monitor the performance indicators of the IoT platform system and collect performance indicator data in real time. Use the Grafana dashboard to visualize the performance indicators and system status. After Flume is completed, combine the performance indicator data with the log data of the IoT platform to analyze the performance of the IoT platform system.

[0038] Prometheus is used to collect performance indicator data in real time, mainly including system CPU usage, memory usage, throughput, latency, error rate and other indicator data.

[0039] And through the IoT platform's log system, collect the running data during the test as log data. Combine the monitoring data with the IoT platform's log data to analyze system performance and find system bottlenecks and potential problems. Provide system optimization suggestions based on the test results to help improve the IoT platform's MQTT protocol processing capabilities and overall performance.

[0040] The method of the present invention can not only generate high-quality test data, but also comprehensively evaluate the MQTT protocol access capability of the Internet of Things platform under conditions closer to the actual production environment, thereby providing performance indicators and improvement suggestions with more reference value.

[0041] Example 2

[0042] The present invention also provides an MQTT access capability evaluation device for an Internet of Things platform, comprising a data generation module, a data reading management module and a monitoring and analysis module.

[0043] The data generation module uses the TSBS tool to generate and save time series data that conforms to the MQTT protocol message format.

[0044] The data reading management module modifies the Flume configuration file: configure the batch processing size batchSize, MQTT topic topic, host information, and spoolDir directory.

[0045] The data reading management module starts Flume to read the time series data generated by TSBS, and sends the time series data to the Memory Channel. It establishes a connection with the MQTT Broker of the IoT platform through the MQTT Sink, reads the time series data from the Memory Channel through the MQTT Sink, and sends the time series data to the specified MQTT topic. It receives the time series data through the MQTT Broker and forwards the time series data to the client that has subscribed to the corresponding topic, simulating the time series data transmission process as the actual MQTT message transmission process.

[0046] The monitoring and analysis module monitors the performance indicators of the IoT platform system through Prometheus and collects performance indicator data in real time. It visualizes the performance indicators and system status through the Grafana dashboard. After Flume runs, it combines the performance indicator data and the log data of the IoT platform to perform IoT platform system performance analysis.

[0047] As the contents of information interaction between modules of the above-mentioned device, execution of readable program process, etc. are based on the same concept as the embodiment of the method of the present invention, the specific contents can be found in the description of the embodiment of the method of the present invention, and will not be repeated here.

[0048] Likewise, the benefits of the device of the present invention are:

[0049] 1. The TSBS tool is used to generate time series data that conforms to the MQTT protocol message format, ensuring the authenticity and representativeness of the test data. The data reporting situation of actual IoT devices is simulated, so that the performance of the system in real scenarios can be more accurately evaluated.

[0050] 2. The configuration and application of Flume tools make data flow processing more efficient and reliable. Data can be transmitted from the generation source to the MQTT Broker in real time, and flow control is implemented to ensure the real-time and integrity of the data.

[0051] 3. Real-time performance monitoring combined with Prometheus can comprehensively track the system's operating status and performance indicators. Through the visual display of the Grafana dashboard, users can intuitively see the performance of the system under different loads and discover potential problems and bottlenecks in a timely manner. This monitoring mechanism not only provides real-time feedback on system operation, but also provides detailed data support for subsequent performance optimization.

[0052] 4. Through automated tools and configurable methods, the process of MQTT protocol access capability testing is simplified and the efficiency of testing is improved. Through systematic testing solutions, manual intervention and errors are reduced, ensuring the accuracy and reliability of test results.

[0053] In summary, the present invention can accurately simulate the actual MQTT message transmission process through advanced data generation and stream processing technology, a comprehensive monitoring mechanism, and a precise evaluation method, improve the efficiency and accuracy of the test, identify the performance bottlenecks and optimization space of the system, and provide an effective solution for the performance testing and optimization of the Internet of Things system, thereby improving the overall performance and stability of the system.

[0054] It should be noted that not all steps and modules in the above-mentioned processes and device structures are necessary, and some steps or modules can be ignored according to actual needs. The execution order of each step is not fixed and can be adjusted as needed. The system structure described in the above-mentioned embodiments can be a physical structure or a logical structure, that is, some modules may be implemented by the same physical entity, or some modules may be implemented by multiple physical entities, or some components in multiple independent devices may be implemented together.

[0055] The above-described embodiments are only preferred embodiments for fully illustrating the present invention, and the protection scope of the present invention is not limited thereto. Equivalent substitutions or changes made by those skilled in the art based on the present invention are within the protection scope of the present invention. The protection scope of the present invention shall be subject to the claims.

Claims

1. A method for evaluating the access capability of an Internet of Things platform MQTT, characterized in that include: Step 1: Use the TSBS tool to generate and save time series data that conforms to the MQTT protocol message format. Step 2: Modify the Flume configuration file: configure the batch processing size batchSize, MQTT topic topic, host information, and spoolDir directory. Step 3: Start Flume to read the time series data generated by TSBS and send the time series data to the Memory Channel. Establish a connection with the MQTT Broker of the IoT platform through the MQTT Sink. Read the time series data from the Memory Channel through the MQTT Sink and send the time series data to the specified MQTT topic. Receive the time series data through the MQTT Broker and forward the time series data to the client that has subscribed to the corresponding topic. Simulate the time series data transmission process as the actual MQTT message transmission process. Step 4: Use Prometheus to monitor the performance indicators of the IoT platform system and collect performance indicator data in real time. Use the Grafana dashboard to visualize the performance indicators and system status. After Flume is completed, combine the performance indicator data with the log data of the IoT platform to analyze the performance of the IoT platform system.

2. According to claim 1, a method for evaluating the access capability of an Internet of Things platform MQTT is characterized in that In step 1, select the CPU-only scenario and use the TSBS tool to generate time series data that conforms to the MQTT protocol message format. Save the generated time series data to a text file for subsequent Flume to read and forward the time series data.

3. The method for evaluating the access capability of an Internet of Things platform MQTT according to claim 1, characterized in that In step 4, Prometheus is used to collect performance indicator data in real time. The performance indicator data includes system CPU usage, memory usage, throughput, latency, and error rate.

4. The method for evaluating the access capability of an Internet of Things platform MQTT according to claim 1, characterized in that In step 4, the operation data during the test is collected as log data through the log system of the IoT platform.

5. A device for evaluating the access capability of an Internet of Things platform MQTT, characterized in that It includes data generation module, data reading management module and monitoring and analysis module. The data generation module uses the TSBS tool to generate and save time series data that conforms to the MQTT protocol message format. The data reading management module modifies the Flume configuration file: configure the batch processing size batchSize, MQTT topic topic, host information, and spoolDir directory. The data reading management module starts Flume to read the time series data generated by TSBS, and sends the time series data to MemoryChannel. It establishes a connection with the MQTT Broker of the IoT platform through MQTT Sink, reads the time series data from MemoryChannel through MQTT Sink, and sends the time series data to the specified MQTT topic. It receives the time series data through MQTT Broker and forwards the time series data to the client that has subscribed to the corresponding topic, simulating the time series data transmission process as the actual MQTT message transmission process. The monitoring and analysis module monitors the performance indicators of the IoT platform system through Prometheus and collects performance indicator data in real time. It visualizes the performance indicators and system status through the Grafana dashboard. After Flume runs, it combines the performance indicator data and the log data of the IoT platform to perform IoT platform system performance analysis.

6. The MQTT access capability evaluation device for an Internet of Things platform according to claim 5, characterized in that The data generation module selects the CPU-only scenario and uses the TSBS tool to generate time series data that conforms to the MQTT protocol message format. The generated time series data is saved in a text file for subsequent Flume to read and forward the time series data.

7. The MQTT access capability evaluation device for an Internet of Things platform according to claim 5, characterized in that The monitoring and analysis module collects performance indicator data in real time through Prometheus. The performance indicator data includes system CPU usage, memory usage, throughput, latency, and error rate.

8. The MQTT access capability evaluation device for an Internet of Things platform according to claim 5, characterized in that The monitoring and analysis module collects the operating data during the test as log data through the log system of the IoT platform.