CN112702225B - Cloud platform performance testing device and method, computer terminal and readable storage medium - Google Patents

Cloud platform performance testing device and method, computer terminal and readable storage medium Download PDF

Info

Publication number
CN112702225B
CN112702225B CN202011456152.4A CN202011456152A CN112702225B CN 112702225 B CN112702225 B CN 112702225B CN 202011456152 A CN202011456152 A CN 202011456152A CN 112702225 B CN112702225 B CN 112702225B
Authority
CN
China
Prior art keywords
equipment
cloud platform
instruction information
virtual
execution module
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011456152.4A
Other languages
Chinese (zh)
Other versions
CN112702225A (en
Inventor
潘永高
张金涛
刘宇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Rootcloud Technology Co Ltd
Original Assignee
Rootcloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Rootcloud Technology Co Ltd filed Critical Rootcloud Technology Co Ltd
Priority to CN202011456152.4A priority Critical patent/CN112702225B/en
Publication of CN112702225A publication Critical patent/CN112702225A/en
Application granted granted Critical
Publication of CN112702225B publication Critical patent/CN112702225B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/50Testing arrangements

Abstract

The embodiment of the invention discloses a cloud platform performance testing device, a cloud platform performance testing method, a computer terminal and a readable storage medium, wherein the device comprises the following components: the system comprises an interaction module, a distributed message publishing module and at least one task execution module; the interaction module issues instruction information to each task execution module through the distributed message issuing module; each task execution module determines the equipment ID corresponding to the instruction information, and determines whether the instruction information can be responded according to the respective equipment ID range, wherein the respective equipment ID ranges are not overlapped; and a task execution module capable of responding to the instruction information determines a target task corresponding to the equipment ID, and controls the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform. According to the invention, a large amount of hardware equipment is not needed for actually butting the cloud platform, so that the test cost is reduced, and the test time is reduced.

Description

Cloud platform performance testing device and method, computer terminal and readable storage medium
Technical Field
The invention relates to the field of Internet of things, in particular to a cloud platform performance testing device and method, a computer terminal and a readable storage medium.
Background
In recent years, the internet of things industry at home and abroad is rapidly developed, and the performance of the cloud platform service is greatly improved. However, in order to detect the function, stability and access performance of the cloud platform, a series of device access tests need to be performed. In the traditional method, a large amount of hardware equipment is used for really docking the cloud platform, and the method is time-consuming, labor-consuming and high in cost.
Disclosure of Invention
In view of the above problems, the present invention provides a cloud platform performance testing apparatus, a cloud platform performance testing method, a computer terminal, and a readable storage medium.
One embodiment of the present invention provides a cloud platform performance testing apparatus, which includes: the system comprises an interaction module, a distributed message publishing module and at least one task execution module;
the interaction module issues instruction information to each task execution module through the distributed message issuing module;
each task execution module determines the equipment ID corresponding to the instruction information, and determines whether the instruction information can be responded according to the respective equipment ID ranges, wherein the respective equipment ID ranges are not coincident;
and a task execution module capable of responding to the instruction information determines a target task corresponding to the equipment ID, and controls the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform.
The cloud platform performance testing device also comprises a task scheduling service module, wherein a preset number of codes are preset in the task scheduling service module, and each code corresponds to one equipment ID range;
each task execution module acquires the corresponding code and the equipment ID range of the virtual equipment corresponding to the code from the task scheduling service module in advance.
In the cloud platform performance testing apparatus according to another embodiment of the present invention, the determining, by each task execution module, an equipment ID corresponding to the instruction information, and determining whether the instruction information can be responded to according to a range of the equipment ID of each task execution module includes:
each task execution module analyzes the instruction information to obtain an equipment identification character string of the virtual equipment to be controlled;
performing hash operation on the equipment identification character string to determine a corresponding hash value;
determining a corresponding remainder result by using the corresponding hash value and the number of the equipment IDs included in each equipment ID range, wherein the corresponding remainder result is used as the equipment ID, and the number of the equipment IDs included in each equipment ID range is the same;
and responding the instruction information by the task execution module corresponding to the equipment ID range in which the equipment ID is positioned.
In the cloud platform performance testing apparatus, the instruction information includes at least one of a virtual device creation instruction and a virtual device control instruction for controlling a virtual device that has been virtually created;
and when the instruction information is a virtual device control instruction, the task execution module responding to the instruction information is further configured to determine whether the virtual device represented by the device ID is created, and if the virtual device represented by the device ID is created, control the virtual device represented by the device ID to execute the target task after determining the target task corresponding to the device ID.
In the cloud platform performance testing apparatus, the virtual device control instruction includes at least one of a virtual device start instruction, a virtual device close instruction, and a virtual device delete instruction.
In the cloud platform performance testing apparatus according to still another embodiment of the present invention, when the instruction information includes device template configuration information, the task execution module responding to the instruction information adds a device template to the virtual device represented by the device ID according to the device template configuration information, where the device template configuration information includes an operation parameter of the virtual device, a method for generating the operation parameter, and a sampling frequency of the operation parameter.
In the cloud platform performance testing apparatus, the method for generating the operating parameter includes at least one of a random generation method within a limited interval, an increment method within a limited interval, a constant method, and a boolean value jump method.
In the cloud platform performance testing device, before the virtual device represented by any device ID under any task execution module is accessed to the cloud platform, the EMQ authentication information is used to verify the virtual device to be accessed, and after the verification is passed, the virtual device to be accessed and the cloud platform establish MQTT connection.
In the cloud platform performance testing device, each task execution module is respectively arranged on different computer terminals.
Another embodiment of the present invention provides a cloud platform performance testing method, including:
receiving instruction information issued in a distributed message sending mode;
determining the equipment ID corresponding to the instruction information, and determining whether the instruction information can be responded according to the equipment ID range of the equipment;
if the instruction information can be responded, determining a target task corresponding to the equipment ID, and controlling the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform;
and if the instruction information cannot be responded, ignoring the instruction information.
The embodiment of the invention relates to a computer terminal which comprises a memory and a processor, wherein the memory is used for storing a computer program, and the computer program executes the cloud platform performance testing method in the embodiment of the invention when running on the processor.
The embodiment of the invention relates to a readable storage medium, which stores a computer program, wherein the computer program executes the cloud platform performance test method in the embodiment of the invention when running on a processor.
The invention discloses a cloud platform performance testing device, which comprises: the system comprises an interaction module, a distributed message publishing module and at least one task execution module; the interaction module issues instruction information to each task execution module through the distributed message issuing module; each task execution module determines the equipment ID corresponding to the instruction information, and determines whether the instruction information can be responded according to the respective equipment ID range, wherein the respective equipment ID ranges are not overlapped; and a task execution module capable of responding to the instruction information determines a target task corresponding to the equipment ID, and controls the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform. According to the technical scheme, a large amount of hardware equipment is not needed for actually butting the cloud platform, so that the test cost is reduced, and the test time is reduced.
Drawings
In order to more clearly illustrate the technical solution of the present invention, the drawings required in the embodiments will be briefly described below, and it should be understood that the following drawings only illustrate some embodiments of the present invention, and therefore should not be considered as limiting the scope of the present invention. Like components are numbered similarly in the various figures.
Fig. 1 shows a schematic structural diagram of a cloud platform performance testing apparatus according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of another cloud platform performance testing apparatus provided in an embodiment of the present invention;
fig. 3 is a schematic flowchart illustrating a method for testing cloud platform performance according to an embodiment of the present invention;
fig. 4 is a flowchart illustrating a corresponding device ID method according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments.
The components of embodiments of the present invention generally described and illustrated in the figures herein may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present invention, as presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present invention without making any creative effort, shall fall within the protection scope of the present invention.
Hereinafter, the terms "including", "having", and their derivatives, which may be used in various embodiments of the present invention, are only intended to indicate specific features, numbers, steps, operations, elements, components, or combinations of the foregoing, and should not be construed as first excluding the existence of, or adding to, one or more other features, numbers, steps, operations, elements, components, or combinations of the foregoing.
Furthermore, the terms "first," "second," "third," and the like are used solely to distinguish one from another, and are not to be construed as indicating or implying relative importance.
Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which various embodiments of the present invention belong. The terms (such as those defined in commonly used dictionaries) should be interpreted as having a meaning that is consistent with their contextual meaning in the relevant art and will not be interpreted in an idealized or overly formal sense unless expressly so defined herein in various embodiments of the present invention.
The invention provides an Internet of things cloud platform performance detection method and system based on an MQTT protocol. The system mainly comprises an interaction module, a distributed message publishing module, a task scheduling service module and at least one task execution module. And the interaction module provides an interface for user interaction, and a user can manage the current equipment template and the virtual equipment through the interaction module. The distributed message issuing module is responsible for receiving instruction information sent by the interaction module, and the instruction message body may contain data such as device Id and operation behavior. The task scheduling service module is responsible for configuring the enabled task execution modules and configuring the device Id ranges that each task execution module needs to be responsible for. The task execution module can continuously create virtual working condition data according to the data creating rule method of each device attribute, meanwhile needs to be responsible for establishing MQTT connection with the cloud platform to be tested, and sends virtual working condition data to the cloud platform at a set frequency so as to simulate the operation of the virtual devices.
Example 1
In this embodiment, referring to fig. 1, a cloud platform performance testing apparatus is shown, the apparatus includes: the system comprises an interaction module, a distributed message publishing module and at least one task execution module.
The interaction module issues the instruction information to each task execution module through the distributed message issuing module; each task execution module determines the equipment ID corresponding to the instruction information, and determines whether the instruction information can be responded according to the respective equipment ID ranges, wherein the respective equipment ID ranges are not overlapped; and the task execution module capable of responding to the instruction information determines a target task corresponding to the equipment ID and controls the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform.
The distributed message publishing module adopts a publishing-subscribing mode, and can ensure the access performance of constant time even for data above TB level; the throughput rate is high, and the single machine can support the transmission of 100K messages per second even on a very cheap commercial machine; and simultaneously, offline data processing and real-time data processing are supported.
Exemplarily, a specific number and a device ID range may be set in advance for each task execution module, the device ID ranges of each task execution module do not overlap, and each task execution module may create and control a virtual device represented by a device ID within its own device ID range.
Further, referring to fig. 2, the cloud platform performance testing apparatus may further include a task scheduling service module, where a preset number of codes are preset in the task scheduling service module, each code corresponds to an equipment ID range, and the equipment ID ranges are not overlapped; each task execution module may obtain, in advance, a corresponding code and a device ID range of the virtual device corresponding to the code from the task scheduling service module. The codes and the device ID ranges of the virtual devices corresponding to the codes may be sequentially allocated to the task scheduling service modules according to the request order of the task scheduling service modules.
It can be understood that, when the device ID range corresponding to a certain number in the task scheduling service module is modified, the task scheduling service module may remind that the device ID range data used by each task execution module is expired, and it is necessary to obtain the latest configuration data from the task scheduling service module in time.
Further, each task execution module determines an equipment ID corresponding to the instruction information, and determines whether the instruction information can be responded according to the respective equipment ID range, including: each task execution module analyzes the instruction information to obtain an equipment identification character string of the virtual equipment to be controlled; performing hash operation on the equipment identification character string to determine a corresponding hash value; dividing the corresponding hash value by the number of the device IDs included in each device ID range to take the result of the remainder operation of the corresponding hash value as the device ID, wherein the number of the device IDs included in each device ID range is the same; and responding the instruction information by the task execution module corresponding to the equipment ID range in which the equipment ID is positioned.
Exemplarily, if the instruction information is as follows:
{
“deviceid”:“abcdefg”,
"action": "creation"
}
If the device identification character string of the virtual device to be controlled is "abcdefg", and the device identification character string determines that the corresponding hash value is 452689632 through hash operation, and the number of the device IDs included in each device ID range is 2000, the result of the remainder operation of dividing 452689632 by 2000 is 1632, and 1632 is located in the device ID range of 1-2000, that is, the task execution module corresponding to the device ID range of 1-2000 responds to the instruction information. It can be understood that the range of the device IDs corresponding to other task execution modules may be 2001-4000, 4001-6000, and the like.
The embodiment discloses a cloud platform capability test device includes: the system comprises an interaction module, a distributed message publishing module and at least one task execution module; the interaction module issues instruction information to each task execution module through the distributed message issuing module; each task execution module determines the equipment ID corresponding to the instruction information, and determines whether the instruction information can be responded according to the respective equipment ID range, wherein the respective equipment ID ranges are not overlapped; and a task execution module capable of responding to the instruction information determines a target task corresponding to the equipment ID, and controls the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform. According to the embodiment, a large amount of hardware equipment is not needed for really docking the cloud platform, so that the test cost is reduced, and the test time is reduced.
Example 2
The instruction information issued by the distributed message issuing module includes at least one of a virtual device creation instruction and a virtual device control instruction for controlling the virtual created virtual device.
And when the instruction information is a virtual device control instruction, the task execution module responding to the instruction information is further configured to determine whether the virtual device represented by the device ID has been created, and if the virtual device represented by the device ID has been created, control the virtual device represented by the device ID to execute the target task after determining the target task corresponding to the device ID.
Exemplarily, the virtual device creating instruction is used for creating the virtual device, the process is to click a creating button on an interface corresponding to the interaction module and fill in related creating information, and the interaction module converts basic creating data information of the virtual device into a json format of the instruction message and sends the json format of the instruction message to the distributed message publishing module. The basic data information includes basic information such as EMQ authentication information of the virtual device. After the task execution module parses the instruction information, if the device Id is located within the range of the task execution module and the target task obtained after parsing is to create a virtual device, the task execution module persists the information of the virtual device in a database.
By way of further example, the instruction information: { "deviceid": "abcdefg", "action": and creating, responding by a task execution module with the equipment ID range of 1-2000, wherein the task execution module with the equipment ID range of 1-2000 creates a virtual equipment with the equipment ID of 1632, and writes the basic information of the virtual equipment into a database.
Further, the virtual device control instruction includes at least one of a virtual device start instruction, a virtual device close instruction, and a virtual device delete instruction.
Exemplarily, the virtual device start instruction is used for starting the virtual device, and the process is that one or more virtual devices are selected on a virtual device list interface of an interface corresponding to the interaction module, and then the interaction module sends the virtual device start instruction to the distributed message service by clicking a start button. After the task execution module analyzes the instruction, if the device Id is within the range of the task execution module and the virtual device needs to be started after the analysis, the task execution module acquires EMQ authentication information from the data and establishes MQTT (Message queue Telemetry Transport) connection with the cloud platform EMQ service. The task execution module stores the connection state of the virtual equipment in a cache, and MQTT long connection of the equipment is realized, so that the state of the virtual equipment which is always on line is presented on the cloud platform.
The EMQ (Erlang/Enterprise/Elastic MQTT Broker) is an open source Internet of things MQTT message server developed based on the Erlang/OTP platform. Erlang/OTP is an excellent Soft-real-time (Soft-real), Low-Latency (Low-Latency), Distributed (Distributed) language platform. MQTT is a lightweight, publish-subscribe-mode, internet-of-things messaging protocol. The EMQ project design aims at bearing massive MQTT connection of a mobile terminal or an Internet of things terminal and realizing rapid low-delay message transmission among massive Internet of things devices.
Exemplarily, the virtual device closing instruction is used for closing the virtual devices, and the process is that one or more virtual devices are selected on a virtual device list interface of an interface corresponding to the interaction module, and then a closing button is clicked, and the interaction module sends an instruction for closing the devices to the distributed message service. After the task execution module analyzes the instruction, if the device ID belongs to the range of the task execution module and the virtual device needs to be closed after the instruction is analyzed, the task execution module searches whether the connection state of the virtual device exists from the cache, and if the connection state of the virtual device exists, the connection state of the virtual device is removed from the cache, so that the MQTT connection state established with the cloud platform EMQ service is disconnected, and the offline state of the device can be presented on the cloud platform.
Exemplarily, the virtual device deleting instruction is used for deleting the virtual devices, and the process is that one or more virtual devices are selected on a virtual device list interface of an interface corresponding to the interaction module, and then a deleting button is clicked, so that the interaction module sends the virtual device deleting instruction to the distributed message service. After the task execution module analyzes the instruction, if the device Id is within the range of the task execution module and the virtual device needs to be deleted after the instruction is analyzed, the task execution module searches whether the device is created from the cache, if the device is created, the information of the virtual device is removed from the cache, the MQTT connection established with the EMQ service of the cloud platform is disconnected, and the cloud platform presents the offline state of the device. And then further deleting the device basis information of the device in the database.
Example 3
And when the instruction information comprises equipment template configuration information, adding an equipment template for the virtual equipment represented by the equipment ID by a task execution module responding to the instruction information according to the equipment template configuration information, wherein the equipment template configuration information comprises operation parameters of the virtual equipment, a method for generating the operation parameters and the sampling frequency of the operation parameters.
Further, the method for generating the operation parameter includes at least one of a random generation method within a limited interval, an increment method within a limited interval, a constant method and a boolean value jump method.
Exemplarily, an equipment template may be created on an interface corresponding to the interaction module, and the equipment attributes (such as oil temperature, speed, pressure, and the like), the frequency of reporting the working condition data (such as 10s, 30 s/time, and the like) and the rule method of data creation included in the template are set. Then under this device template, N (N > ═ 0) virtual devices are created. Each virtual device has the same device attribute and data reporting frequency, and continuously generates working condition data to the cloud platform by adopting the same rule. The data rule making method specifically comprises the conditions of a random generation method in a limited interval, an increasing method in the limited interval, a constant method, a Boolean value hopping method and the like. Each generated virtual device is bound with unique EMQ authentication information, and the authentication information is composed of a group of account passwords and aims to establish connection with the EMQ service of the cloud platform.
Further, referring to fig. 2, the cloud platform performance testing apparatus further includes a data storage module, configured to store the instruction information sent by the interaction module, the attribute information of the virtual device created by each task execution module, and the operation information of each virtual device accessing the cloud platform.
Further, before the virtual device represented by any device ID under any task execution module is accessed to the cloud platform, the virtual device to be accessed is verified by using EMQ authentication information, and after the virtual device to be accessed is verified, MQTT connection is established between the virtual device to be accessed and the cloud platform.
Furthermore, each task execution module is respectively arranged on different computer terminals. The cloud platform test system is deployed through multiple machines, the number of virtual devices can be effectively increased through the multiple task execution modules, the device access condition of the cloud platform is truly reflected, and the limitation of single-machine deployment is avoided.
Furthermore, the interaction module, the distributed message publishing module and the task scheduling service module can be deployed on one computer terminal, and the interaction module, the distributed message publishing module and the task scheduling service module can also be deployed on different computer terminals.
Example 4
In this embodiment, referring to fig. 3, it is shown that a cloud platform performance testing method includes the following steps:
s100: and receiving instruction information issued by a distributed message sending mode.
It can be understood that each task execution module receives the instruction information sent by the interaction module through the distributed message issuing module.
S200: and determining the device ID corresponding to the instruction information.
S300: and determining whether the instruction information can be responded according to the ID range of the device.
If the instruction information can be responded, step S400 is executed, and if the instruction information cannot be responded, step S500 is executed.
S400: and determining a target task corresponding to the equipment ID, and controlling the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform.
S500: the instruction information is ignored.
Further, as shown in fig. 4, determining the device ID corresponding to the instruction information, and determining whether the instruction information can be responded according to the respective device ID ranges, includes the following steps:
s10: each task execution module analyzes the instruction information to obtain an equipment identification character string of the virtual equipment to be controlled;
s20: performing hash operation on the equipment identification character string to determine a corresponding hash value;
s30: determining a corresponding remainder result by using the corresponding hash value and the number of the equipment IDs included in each equipment ID range, wherein the corresponding remainder result is used as the equipment ID, and the number of the equipment IDs included in each equipment ID range is the same;
s40: and responding the instruction information by the task execution module corresponding to the equipment ID range in which the equipment ID is positioned.
Exemplarily, an apparatus identification character string of the virtual apparatus to be controlled is "abcdefg", if the apparatus identification character string determines, through hash operation, that a corresponding hash value is 452689632, and the number of apparatus IDs included in each apparatus ID range is 2000, a result of the remainder operation of 452689632 divided by 2000 is 1632, and 1632 is located in an apparatus ID range of 1 to 2000, that is, the task execution module corresponding to the apparatus ID range of 1 to 2000 responds to the instruction information. The range of the ID of the corresponding equipment of other task execution modules can be 2001-4000, 4001-6000 and the like.
It can be understood that the embodiment of the present invention relates to a computer terminal, which includes a memory and a processor, where the memory is used for storing a computer program, and the computer program executes the cloud platform performance test method according to the embodiment of the present invention when running on the processor.
It is to be understood that the present invention relates to a readable storage medium, which stores a computer program, and when the computer program runs on a processor, the computer program performs the cloud platform performance testing method according to the present invention.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method can be implemented in other ways. The apparatus embodiments described above are merely illustrative and, for example, the flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, each functional module or unit in each embodiment of the present invention may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
The functions, if implemented in the form of software functional modules and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention or a part thereof which contributes to the prior art in essence can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing a computer device (which may be a smart phone, a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily think of the changes or substitutions within the technical scope of the present invention, and shall cover the scope of the present invention.

Claims (11)

1. A cloud platform performance testing device, the device comprising: the system comprises an interaction module, a distributed message publishing module and at least one task execution module;
the interaction module issues instruction information to each task execution module through the distributed message issuing module;
each task execution module analyzes the instruction information to obtain an equipment identification character string of the virtual equipment to be controlled;
performing hash operation on the equipment identification character string to determine a corresponding hash value;
determining a corresponding remainder result by using the corresponding hash value and the number of the equipment IDs included in each equipment ID range, wherein the corresponding remainder result is used as the equipment ID, the number of the equipment IDs included in each equipment ID range is the same, and the equipment ID ranges are not overlapped with each other;
the task execution module corresponding to the equipment ID range in which the equipment ID is positioned responds to the instruction information;
a task execution module capable of responding to the instruction information determines a target task corresponding to the equipment ID, and controls virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform;
and when the instruction information comprises equipment template configuration information, adding an equipment template for the virtual equipment represented by the equipment ID by the task execution module responding to the instruction information according to the equipment template configuration information, and setting equipment attributes and a rule method of manufacturing data contained in the equipment template.
2. The cloud platform performance testing device of claim 1, further comprising a task scheduling service module, wherein a preset number of codes are preset in the task scheduling service module, and each code corresponds to one device ID range;
each task execution module acquires the corresponding code and the equipment ID range of the virtual equipment corresponding to the code from the task scheduling service module in advance.
3. The cloud platform performance testing apparatus according to claim 1, wherein the instruction information includes at least one of a virtual device creation instruction and a virtual device control instruction that controls the virtual device that has been virtually created;
and when the instruction information is a virtual device control instruction, the task execution module responding to the instruction information is further configured to determine whether the virtual device represented by the device ID has been created, and if the virtual device represented by the device ID has been created, control the virtual device represented by the device ID to execute the target task after determining the target task corresponding to the device ID.
4. The cloud platform performance testing apparatus according to claim 3, wherein the virtual device control instruction includes at least one of a virtual device start instruction, a virtual device close instruction, and a virtual device delete instruction.
5. The cloud platform performance testing apparatus of claim 1, wherein the device template configuration information includes operating parameters of a virtual device, a method of generating the operating parameters, and a sampling frequency of the operating parameters.
6. The cloud platform performance testing apparatus of claim 5, wherein the method of generating the operating parameter comprises at least one of a random generation method within a finite interval, an increment method within a finite interval, a constant method, and a Boolean jump method.
7. The cloud platform performance testing device according to claim 1, wherein before accessing the cloud platform, the virtual device represented by any device ID under any task execution module verifies the virtual device to be accessed by using EMQ authentication information, and after the verification is passed, the virtual device to be accessed establishes MQTT connection with the cloud platform.
8. The cloud platform performance testing device of claim 1, wherein each task execution module is respectively arranged on different computer terminals.
9. A cloud platform performance testing method is characterized by comprising the following steps:
receiving instruction information issued in a distributed message sending mode;
analyzing the instruction information to obtain an equipment identification character string of the virtual equipment to be controlled;
performing hash operation on the equipment identification character string to determine a corresponding hash value;
determining a corresponding remainder result by using the corresponding hash value and the number of the equipment IDs included in each equipment ID range, wherein the corresponding remainder result is used as the equipment ID, the number of the equipment IDs included in each equipment ID range is the same, and the equipment ID ranges are not overlapped with each other;
determining whether the instruction information can be responded according to the equipment ID range in which the equipment ID is positioned;
if the instruction information can be responded, determining a target task corresponding to the equipment ID, and controlling the virtual equipment represented by the equipment ID to execute the target task, wherein the target task is used for testing the cloud platform;
when the instruction information comprises equipment template configuration information, responding to the instruction information to add an equipment template for the virtual equipment represented by the equipment ID according to the equipment template configuration information, and setting equipment attributes and rule methods of manufacturing data contained in the equipment template;
and if the instruction information cannot be responded, ignoring the instruction information.
10. A computer terminal comprising a memory and a processor, the memory for storing a computer program which, when run on the processor, performs the cloud platform performance testing method of claim 9.
11. A readable storage medium storing a computer program which, when executed on a processor, performs the cloud platform performance testing method of claim 9.
CN202011456152.4A 2020-12-10 2020-12-10 Cloud platform performance testing device and method, computer terminal and readable storage medium Active CN112702225B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011456152.4A CN112702225B (en) 2020-12-10 2020-12-10 Cloud platform performance testing device and method, computer terminal and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011456152.4A CN112702225B (en) 2020-12-10 2020-12-10 Cloud platform performance testing device and method, computer terminal and readable storage medium

Publications (2)

Publication Number Publication Date
CN112702225A CN112702225A (en) 2021-04-23
CN112702225B true CN112702225B (en) 2022-09-30

Family

ID=75509027

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011456152.4A Active CN112702225B (en) 2020-12-10 2020-12-10 Cloud platform performance testing device and method, computer terminal and readable storage medium

Country Status (1)

Country Link
CN (1) CN112702225B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113434421B (en) * 2021-06-30 2023-10-24 青岛海尔科技有限公司 Virtual equipment testing method and device
CN113434422B (en) * 2021-06-30 2024-01-23 青岛海尔科技有限公司 Virtual device debugging method and device and virtual device debugging system

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110377232A (en) * 2019-07-19 2019-10-25 苏州浪潮智能科技有限公司 A kind of method, apparatus and system for disposing distributed storage cluster

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI476586B (en) * 2011-07-13 2015-03-11 Inst Information Industry Cloud-based test system, method and computer readable storage medium storing thereof
CN105491140B (en) * 2015-12-15 2019-07-19 上海斐讯数据通信技术有限公司 Remote testing method and system for terminal
CN107967284B (en) * 2016-10-20 2022-07-05 北京京东尚科信息技术有限公司 Method and device for storing and inquiring order information
US10805104B2 (en) * 2018-06-26 2020-10-13 Verizon Patent And Licensing Inc. Virtual network endpoints for internet of things (IOT) devices
CN110798405A (en) * 2018-08-01 2020-02-14 中国电信股份有限公司 Data tunnel exchange method, device and system
CN111865708B (en) * 2019-12-30 2022-05-27 北京嘀嘀无限科技发展有限公司 Performance test method, platform, equipment and storage medium of Internet of things system
CN111262759B (en) * 2020-03-17 2022-01-11 中国建设银行股份有限公司 Internet of things platform testing method, device, equipment and storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110377232A (en) * 2019-07-19 2019-10-25 苏州浪潮智能科技有限公司 A kind of method, apparatus and system for disposing distributed storage cluster

Also Published As

Publication number Publication date
CN112702225A (en) 2021-04-23

Similar Documents

Publication Publication Date Title
US10296563B2 (en) Automated testing of perceptible web page elements
WO2020005728A1 (en) Artificial intelligence assisted content authoring for automated agents
US9053435B2 (en) Generating application models based on discovery based machine learning
CN112702225B (en) Cloud platform performance testing device and method, computer terminal and readable storage medium
CN108111364B (en) Service system testing method and device
US20230403215A1 (en) Systems and methods of monitoring and controlling remote assets
CN110659202A (en) Client automatic testing method and device
CN111045893A (en) Method, device and system for executing monitoring task, storage medium and electronic device
CN112380145A (en) SDK generation method, device, equipment and readable storage medium
CN107113199B (en) Analysis device for analyzing and processing communication sequences
CN109491702B (en) Optimization scheme determination method and device, terminal equipment and storage medium
CN115774707B (en) Object attribute-based data processing method and device, electronic equipment and storage medium
CN113495723B (en) Method, device and storage medium for calling functional component
CN113297072B (en) Container testing method and device
CN114817482A (en) Method, device and equipment for determining product manufacturing program and storage medium
CN113610242A (en) Data processing method and device and server
KR20140121583A (en) Method and system for certifying application
CN114610446A (en) Method, device and system for automatically injecting probe
US9864585B2 (en) Rapid prototyping of backend services
CN113094367A (en) Data processing method and device and server
CN113806327A (en) Database design method and device and related equipment
CN115004667A (en) Information pushing method and device, electronic equipment and computer readable medium
EP3379409A1 (en) Automated program code analysis and reporting
CN114880157B (en) Fault injection method and device
CN112560462B (en) Event extraction service generation method, device, server and medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
CB02 Change of applicant information
CB02 Change of applicant information

Address after: Room 303-309, No.3, Pazhou Avenue East Road, Haizhu District, Guangzhou City, Guangdong Province 510000

Applicant after: Shugen Internet Co.,Ltd.

Address before: Unit 12-30, 4th floor, Xigang office building, Guangzhou international media port, 218 and 220 Yuejiang West Road, Haizhu District, Guangzhou City, Guangdong Province 510000

Applicant before: IROOTECH TECHNOLOGY Co.,Ltd.

SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant