A method and device for alarm stress testing based on JMeter simulation of dynamic environment equipment

JMeter simulates the dynamic ring equipment to perform alarm pressure measurement, solves the problem that the existing technology cannot simulate large-scale alarm data, realizes system performance testing and alarm time automatic calculation, and ensures system stability and equipment performance understanding.

CN115883326BActive Publication Date: 2024-12-27CHINA UNITECHS
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211562307.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-12-07
Publication Date
2024-12-27
Estimated Expiration
2042-12-07

AI Technical Summary

Technical Problem

The existing technology cannot effectively simulate large-scale alarm data, resulting in the inability to understand the equipment performance and control service processing capabilities, resulting in system pressure and unresponsiveness of services.

Method used

JMeter simulates dynamic ring equipment for alarm pressure measurement, monitors alarm time through automated scripts, generates alarm IDs and rules, configures HTTP header managers and thread groups, scans logs one by one to calculate the time spent on alarms, and realizes automatic pressure measurement of alarm quantity and Performance test.

Benefits of technology

With the realization that without damaging the equipment, the system's alarm module performance is tested by simulating the equipment, ensuring system stability, and automatically calculating the alarm time and defining the alarm quantity, which improves the operation and maintenance personnel's understanding and control of equipment performance. Service expansion capacity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115883326B_ABST
    Figure CN115883326B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and device for alarm stress testing based on JMeter simulation of dynamic environment equipment, the method comprising: S01, simulating dynamic environment alarms and configuring alarm rules; S02, alarm monitoring, monitoring the alarm module receiving alarm time through an automated script. The present invention uses the alarm generated by the acquisition and control system for the dynamic environment plug-in to test its performance and formulate stress testing, and can also be used as an independent alarm stress testing module, which is issued through a simulation device, without damaging the device, and can check the system's alarm module performance, thereby achieving the goal of ensuring system stability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of acquisition and control, and in particular to a method and a device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment. Background Art

[0002] The devices connected to the dynamic ring plug-in are all real live network devices. There is no way to send a large number of alarms to meet the number of alarms required for stress testing. Therefore, the JMeter stress testing tool is used to simulate the device to batch send the dynamic ring alarm interface; because the alarm processing logic from reception to push is performed in the background, there is no way to intuitively understand the time required for an alarm from reception to push.

[0003] The interface of the dynamic ring is relatively independent, and the performance of the dynamic ring FSU equipment is not perceptible. It is impossible to understand the performance of the equipment, and the processing capacity of the control service is also unknown. As a result, the operation and maintenance personnel cannot expand the control service according to the number of managed devices. It is also easy to cause system pressure due to the large number of connected devices, resulting in problems such as service failure to respond.

[0004] Existing tests cannot simulate large-scale alarm data, and the test result data cannot reflect the performance bottleneck of the system. Summary of the invention

[0005] In order to solve the problems existing in the prior art, the present invention provides a method and device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment. The stress test formulated by testing the performance of the dynamic environment plug-in through the alarm generated by the acquisition and control system can also be used as an independent alarm stress testing module. It can be issued through the simulation device without damaging the equipment and can check the performance of the system's alarm module, thereby achieving the goal of ensuring system stability.

[0006] To achieve the above object, the present invention adopts the following technical solutions:

[0007] In one embodiment of the present invention, a method for performing alarm stress testing based on JMeter simulating dynamic environment equipment is proposed, and the method includes:

[0008] S01, simulate dynamic environment alarm and configure alarm rules;

[0009] S02. Alarm monitoring: monitor the alarm module’s alarm receiving time through automated scripts.

[0010] Further, the S01 includes:

[0011] S011. Use Python script to generate variable input parameters to ensure that the alarm IDs are different;

[0012] S012, the dynamic ring plug-in interface is a webservice interface, and the JMeter configuration is configured for the webservice protocol;

[0013] S013. Configure alarm rules.

[0014] Furthermore, the JMeter configuration information in S012 includes: HTTP header manager, HTTP request, and thread group.

[0015] Furthermore, the thread group alarm quantity increases sequentially.

[0016] The stress testing solution can be reused. If it is a POST interface, the HTTP header information needs to be modified;

[0017] Before stress testing, you need to issue 10 alarms to verify whether the alarm function is normal.

[0018] Furthermore, the S013 includes: for the dynamic environment alarm SYSLOG message, entering the alarm processing rules into the acquisition and control system, and performing SYSLOG rule testing.

[0019] SYSLOG rules can be imported in batches to ensure that the dynamic environment alarms hit the dynamic environment general alarms before stress testing.

[0020] Because the number of alarm rules will also affect the time of alarm push, this influencing factor must also be taken into account, and multiple non-dynamic alarm rules need to be prepared in advance.

[0021] Further, the S02 includes:

[0022] S021. Monitor the alarm module’s alarm reception time through an automated script, and generate the file name, time used, number of times used, total number of times received, and percentage of times used;

[0023] S022. Scan all alarm logs one by one. The Python script calculates the number of alarms received by counting, and then calculates the time used for each alarm by subtracting the time of alarm reception from the time of alarm push.

[0024] Furthermore, the calculation formula for the time used for each alarm is:

[0025]

[0026] x represents the different time required from receiving an alarm to pushing it, and w represents the number of alarms that take x time.

[0027] In one embodiment of the present invention, a device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment is also proposed, and the device includes:

[0028] Simulate the dynamic ring alarm module, use Python script to batch generate dynamic ring interface input parameters, ensure that the alarm ID, alarm description and other contents are different, and the alarm ID increases in sequence, which is convenient for subsequent query of alarm information. Use JMeter stress testing tool to set the input parameter alarm content as a variable; set variables such as the number of threads and the number of loops so that the number of alarms can increase in sequence, and the alarm matching alarm rules adopt the traversal method;

[0029] The alarm monitoring module monitors the alarm module's acceptance time through automated scripts.

[0030] Furthermore, the alarm rules are as follows: add the required alarm rules to the alarm rule template in advance, and import them into the acquisition and control system in batches during the stress test; when the alarm volume and alarm rule volume are large, check the average time of the complete process of pushing alarms to Kafka through the result file finally formed by the Python script.

[0031] In one embodiment of the present invention, a computer device is also proposed, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the aforementioned method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment is implemented.

[0032] In one embodiment of the present invention, a computer-readable storage medium is further proposed, which stores a computer program for executing a method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment.

[0033] Beneficial effects:

[0034] The present invention uses the alarm generated by the acquisition and control system on the dynamic ring plug-in to test its performance and formulate a stress test. It can also be used as an independent alarm stress test module and sent through a simulation device. It does not damage the device and can check the performance of the system's alarm module to achieve the goal of ensuring system stability. The present invention automates stress testing and the alarm quantity can be defined by oneself. The present invention automatically calculates the alarm time. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 It is a flow chart of a method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment in the present invention;

[0036] Figure 2 It is a schematic diagram of the structure of the device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment in the present invention;

[0037] Figure 3 It is a schematic diagram of the structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0038] The principles and spirit of the present invention will be described below with reference to several exemplary embodiments. It should be understood that these embodiments are provided only to enable those skilled in the art to better understand and implement the present invention, and are not intended to limit the scope of the present invention in any way. On the contrary, these embodiments are provided to make the present disclosure more thorough and complete, and to fully convey the scope of the present disclosure to those skilled in the art.

[0039] Those skilled in the art will appreciate that the embodiments of the present invention may be implemented as a system, device, apparatus, method or computer program product. Therefore, the present disclosure may be specifically implemented in the following forms, namely: complete hardware, complete software (including firmware, resident software, microcode, etc.), or a combination of hardware and software.

[0040] The terms and their explanations involved in the present invention are:

[0041] JMeter:

[0042] JMeter is a Java-based stress testing tool developed by the Apache organization and is used to perform stress testing on software.

[0043] JMeter was originally designed for Web application testing, but later expanded to other testing areas. It can be used to test static and dynamic resources, such as static files, Java servlets, CGI scripts, Java objects, databases, and FTP servers, etc. JMeter can simulate huge loads on servers, networks, or objects, test their strength under different stress categories, and analyze overall performance. In addition, JMeter can perform functional / regression testing on applications by creating scripts with assertions to verify whether the program returns the expected results. For maximum flexibility, JMeter allows the use of regular expressions to create assertions.

[0044] Python:

[0045] Python is a cross-platform computer programming language, a substitute for ABC language, and an object-oriented dynamic type language.

[0046] kafka:

[0047] Kafka is a high-throughput distributed publish-subscribe messaging system that can handle all the action stream data of consumers in the website.

[0048] According to the implementation mode of the present invention, a method and device for alarm stress testing based on JMeter simulation of dynamic environment equipment are proposed. The stress test formulated by testing the performance of the dynamic environment plug-in through the alarm generated by the acquisition and control system can also be used as an independent alarm stress testing module. It can be issued through the simulation device without damaging the equipment and can check the performance of the system's alarm module, thereby achieving the goal of ensuring system stability.

[0049] The principle and spirit of the present invention are explained in detail below with reference to several representative embodiments of the present invention.

[0050] like Figure 1 As shown, the method includes:

[0051] S01, simulate dynamic environment alarm and configure alarm rules;

[0052] S02. Alarm monitoring: monitor the alarm module’s alarm receiving time through automated scripts.

[0053] The S01 includes:

[0054] S011. Use Python script to generate variable input parameters to ensure that the alarm IDs are different;

[0055] S012, the dynamic ring plug-in interface is a webservice interface, and the JMeter configuration is configured for the webservice protocol;

[0056] S013. Configure alarm rules.

[0057] The JMeter configuration information in S012 includes: HTTP header manager, HTTP request, and thread group.

[0058] The thread group alarm quantity increases sequentially.

[0059] The stress testing solution can be reused. If it is a POST interface, the HTTP header information needs to be modified;

[0060] Before stress testing, you need to issue 10 alarms to verify whether the alarm function is normal.

[0061] Furthermore, the S013 includes: for the dynamic environment alarm SYSLOG message, entering the alarm processing rules into the acquisition and control system, and performing SYSLOG rule testing.

[0062] SYSLOG rules can be imported in batches to ensure that the dynamic environment alarms hit the dynamic environment general alarms before stress testing.

[0063] Because the number of alarm rules will also affect the time of alarm push, this influencing factor must also be taken into account, and multiple non-dynamic alarm rules need to be prepared in advance.

[0064] The S02 includes:

[0065] S021. Monitor the alarm module’s alarm reception time through an automated script, and generate the file name, time used, number of times used, total number of times received, and percentage of times used;

[0066] S022. Scan all alarm logs one by one. The Python script calculates the number of alarms received by counting, and then calculates the time used for each alarm by subtracting the time of alarm reception from the time of alarm push.

[0067] The calculation formula for the time used for each alarm is:

[0068]

[0069] x represents the different time required from receiving an alarm to pushing it, and w represents the number of alarms that take x time.

[0070] It should be noted that, although the operations of the method of the present invention are described in a specific order in the above embodiments and the accompanying drawings, this does not require or imply that the operations must be performed in the specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.

[0071] In order to more clearly explain the above-mentioned method of performing alarm stress testing based on JMeter simulation of dynamic environment equipment, a specific embodiment is used for illustration below. However, it is worth noting that this embodiment is only for better illustrating the present invention and does not constitute an improper limitation to the present invention.

[0072] S01, simulate dynamic environment alarm and configure alarm rules;

[0073] S02. Alarm monitoring: monitor the alarm module’s alarm receiving time through automated scripts.

[0074] The S01 includes:

[0075] S011. Use Python script to generate variable input parameters to ensure that the alarm IDs are different;

[0076] The Python script is as follows:

[0077] file="D: / 123.txt"

[0078] f = open(file, mode = 'w')

[0079] for i in range(100000,130000):

[0080] i+=1

[0081] f.write(" <values> <talarmlist> <talarm> <serialno>0000")

[0082] f.write(i.__str__())

[0083] f.write("< / serialno> <suid> 12-23-5D-D5-18-C4< / suid> <deviceid> 2120016< / deviceid> <spid> 211200040010< / spid> ")

[0084] f.write(" <starttime> 2022-03-09

[0085] 10:01:21< / starttime> <endtime> 2022-03-0915:31:55< / endtime> ")

[0086] f.write(" <triggerval> 23< / triggerval> <alarmlevel> 2< / alarmlevel> <alarmflag> 0< / alarmflag> <alarmdesc>")

[0087] f.write(i.__str__())

[0088] f.write("Dynamic ring general alarm< / alarmdesc> <alarmfridesc / > < / talarm> < / talarmlist> < / values> \n")

[0089] f.flush()

[0090] f.close()

[0091] S012, the dynamic ring plug-in interface is a webservice interface, and the JMeter configuration is configured for the webservice protocol;

[0092] S013. Configure alarm rules.

[0093] The JMeter configuration information in S012 includes: HTTP header manager, HTTP request, and thread group.

[0094] JMeter related configuration:

[0095] ①HTTP header manager is as shown in Table 1.

[0096] Content-Type application / json

[0097] Table 1

[0098] ②HTTP request

[0099] The input message <info>< / info> The content between is a variable

[0100] Here is an example:

[0101] <soapenv:Envelopexmlns:soapenv="http: / / schemas.xmlsoap.org / soap / envelope / "xmlns:scs="http: / / SCService.chinatelecom.com">

[0102] <soapenv:header / >

[0103] <soapenv:body>

[0104] <scs:invoke>

[0105] <xmldata>

[0106] <![CDATA[

[0107] <request>

[0108] <PK_Type>

[0109] <name> SEND_ALARM< / name>

[0110] <code>601< / code>

[0111] < / PK_Type>

[0112] <info>

[0113] ${info}

[0114] < / info>

[0115] < / request>

[0116] ]]>

[0117] < / xmldata>

[0118] < / scs:invoke>

[0119] < / soapenv:body>

[0120]

[0121] ③The thread group is as shown in Table 2.

[0122] Number of threads 50 Cycle times 300

[0123] Table 2

[0124] The thread group settings increase in sequence according to the alarm quantity, which is subject to the actual test alarm quantity.

[0125] Instructions:

[0126] The stress testing solution can be reused. If it is a POST interface, the HTTP header information needs to be modified.

[0127] Before stress testing, you need to issue 10 alarms to verify whether the alarm function is normal.

[0128] Furthermore, the S013 includes: for the dynamic environment alarm SYSLOG message, entering the alarm processing rules into the acquisition and control system, and performing SYSLOG rule testing.

[0129] SYSLOG rules can be imported in batches to ensure that the dynamic environment alarms hit the dynamic environment general alarms before stress testing.

[0130] The dynamic environment alarm SYSLOG rules are as follows:

[0131]

[0132]

[0133] Table 3

[0134] Because the number of alarm rules will also affect the time of alarm push, this influencing factor must also be taken into account, and 6,000 non-dynamic environment alarm rules need to be prepared in advance.

[0135] The S02 includes:

[0136] S021. Monitor the alarm module receiving alarm time, file name, time taken (s), number of times taken, total number of times received, and percentage of times taken (%) through automated scripts;

[0137] Finally, the result is formed, as follows:

[0138] Syslog quantity: 100 per second, for 500 seconds

[0139] Detailed alarm duration statistics:

[0140] File name, time taken (s), number of times taken, total number of times received, percentage of time taken (%)

[0141] testalarm.log-10000r+100000n:100,11,8344,50000,16.69

[0142] testalarm.log-10000r+100000n:100,7,2367,50000,4.73

[0143] testalarm.log-10000r+100000n:100,17,272,50000,0.54

[0144] testalarm.log-10000r+100000n:100,18,21,50000,0.04

[0145] testalarm.log-10000r+100000n:100,16,1144,50000,2.29

[0146] testalarm.log-10000r+100000n:100,13,5905,50000,11.81

[0147] testalarm.log-10000r+100000n:100,6,863,50000,1.73

[0148] testalarm.log-10000r+100000n:100,3,1,50000,0.00

[0149] testalarm.log-10000r+100000n:100,9,5443,50000,10.89

[0150] testalarm.log-10000r+100000n:100,12,7469,50000,14.94

[0151] testalarm.log-10000r+100000n:100,15,2597,50000,5.19

[0152] testalarm.log-10000r+100000n:100,14,3728,50000,7.46

[0153] testalarm.log-10000r+100000n:100,8,4310,50000,8.62

[0154] testalarm.log-10000r+100000n:100,4,30,50000,0.06

[0155] testalarm.log-10000r+100000n:100,10,7367,50000,14.73

[0156] testalarm.log-10000r+100000n:100,19,5,50000,0.01

[0157] testalarm.log-10000r+100000n:100,5,134,50000,0.27

[0158] The average time from alarm reception to alarm push is 11.05s.

[0159] S022. Scan all alarm logs one by one. The Python script calculates the number of alarms received by counting, and then calculates the time used for each alarm by subtracting the time of alarm reception from the time of alarm push.

[0160] The calculation formula for the time used for each alarm is:

[0161]

[0162] x represents the different time required from receiving an alarm to pushing it, and w represents the number of alarms that take x time.

[0163] For example, the complete alarm process takes 11 seconds, of which 8,344 alarms take 11 seconds, and a total of 50,000 alarms are hit, accounting for 15.6%.

[0164] Based on the same inventive concept, the present invention also proposes a device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment. The implementation of the device can refer to the implementation of the above method, and the repeated parts will not be repeated. The term "module" used below can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.

[0165] Figure 2 This is a schematic diagram of the structure of the device for alarm stress testing based on JMeter simulation of dynamic environment equipment in the present invention. Figure 2 As shown, the device comprises:

[0166] Simulate the dynamic ring alarm module 110, use Python script to batch generate dynamic ring interface input parameters, ensure that the alarm ID, alarm description and other contents are different, and the alarm ID increases in sequence, which is convenient for subsequent query of alarm information. Use JMeter stress testing tool to set the input parameter alarm content as a variable; set variables such as the number of threads and the number of loops so that the number of alarms can increase in sequence, and the alarm matching alarm rules adopt a traversal method;

[0167] The alarm monitoring module 120 monitors the alarm module receiving alarm time through automated scripts, receives alarms, matches alarm rules, and pushes alarms. It checks whether the number of alarms received by Kafka is equal to the number of alarms sent.

[0168] Write a Python script to use the weighted average to calculate the proportion and average time of different times in an alarm stress test, and finally output the time data file

[0169] The alarm rules are as follows: add the required alarm rules to the alarm rule Gaoru template in advance, and import them into the acquisition and control system in batches during the stress test; when the alarm volume and alarm rule volume are large, check the average time of the complete process of pushing alarms to Kafka through the result file finally formed by the Python script.

[0170] It should be noted that although several modules of the device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment are mentioned in the above detailed description, this division is only exemplary and not mandatory. In fact, according to an embodiment of the present invention, the features and functions of two or more modules described above can be concretized in one module. Conversely, the features and functions of one module described above can be further divided into multiple modules for concretization.

[0171] Based on the above invention concept, Figure 3 As shown, the present invention also proposes a computer device 200, including a memory 210, a processor 220, and a computer program 230 stored in the memory 210 and executable on the processor 220. When the processor 220 executes the computer program 230, the aforementioned method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment is implemented.

[0172] Based on the aforementioned inventive concept, the present invention further proposes a computer-readable storage medium, which stores a computer program for executing the aforementioned method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment.

[0173] The present invention is based on the method of JMeter simulating dynamic environment equipment to perform alarm stress testing. The stress testing formulated by the alarm generated by the acquisition and control system for the dynamic environment plug-in tests its performance. It can also be used as an independent alarm stress testing module and sent through the simulation device. It does not damage the equipment and can check the performance of the system's alarm module, thereby achieving the goal of ensuring system stability. The present invention automates stress testing, and the alarm quantity can be defined by oneself. The present invention automatically calculates the alarm time.

[0174] Although the spirit and principle of the present invention have been described with reference to several specific embodiments, it should be understood that the present invention is not limited to the disclosed specific embodiments, and the division of various aspects does not mean that the features in these aspects cannot be combined to benefit, and such division is only for the convenience of expression. The present invention is intended to cover various modifications and equivalent arrangements contained in the spirit and scope of the attached claims.

[0175] Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various implementations can include: being implemented in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a special purpose or general purpose programmable processor that can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.

[0176] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.

[0177] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.

[0178] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, voice input, or tactile input).

[0179] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.

[0180] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.

[0181] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.

[0182] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.

[0183] Regarding the limitation of the protection scope of the present invention, those skilled in the art should understand that, based on the technical solution of the present invention, various modifications or variations that can be made by those skilled in the art without creative work are still within the protection scope of the present invention.

Claims

1. A method for alarm stress testing based on JMeter simulation of dynamic environment equipment, characterized in that: The method includes: S01, simulate dynamic environment alarm and configure alarm rules; S02, alarm monitoring, through the automated script, monitors the alarm module to receive the alarm time, including: S021. Monitor the alarm module’s alarm reception time through an automated script, and generate the file name, time used, number of times used, total number of times received, and percentage of times used; S022. Scan all alarm logs one by one. The Python script counts the number of alarms received, and then calculates the time taken for each alarm by subtracting the time taken for the alarm to be received from the time the alarm was pushed. The time taken for each alarm is calculated as follows: x represents the different time required from receiving an alarm to pushing it, and w represents the number of alarms that take x time.

2. The method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment according to claim 1 is characterized in that: The S01 includes: S011. Use Python script to generate variable input parameters to ensure that the alarm IDs are different; S012, the dynamic ring plug-in interface is a webservice interface, and the JMeter configuration is configured for the webservice protocol; S013. Configure alarm rules.

3. The method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment according to claim 2 is characterized in that: The JMeter configuration information in S012 includes: HTTP header manager, HTTP request, and thread group.

4. The method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment according to claim 3 is characterized in that: The thread group alarm quantity increases sequentially.

5. The method for performing alarm stress testing based on JMeter simulation of dynamic environment equipment according to claim 2 is characterized in that: The S013 includes: for the dynamic environment alarm SYSLOG message, entering the alarm processing rules in the acquisition and control system, and performing SYSLOG rule testing; the SYSLOG rules can be imported in batches, and before the stress test, it is sufficient to ensure that the dynamic environment alarm hits the dynamic environment general alarm.

6. A device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment, characterized in that: The device includes: Simulate the dynamic ring alarm module, use Python script to batch generate dynamic ring interface input parameters, ensure that the alarm ID, alarm description and other contents are different, and the alarm ID increases in sequence, which is convenient for subsequent query of alarm information. Use JMeter stress testing tool to set the input parameter alarm content as a variable; set variables such as the number of threads and the number of loops so that the number of alarms can increase in sequence, and the alarm matching alarm rules adopt the traversal method; The alarm monitoring module uses automated scripts to monitor the alarm module's alarm receiving time, including: Through automated scripts, monitor the alarm module to receive alarms, generate file names, time taken, times taken, total times received, and percentage of times taken; Scan all alarm logs one by one. The Python script calculates the number of alarms received by counting, and then calculates the time taken for each alarm by subtracting the time taken for the alarm to be received from the time the alarm was pushed. The time taken for each alarm is calculated as follows: x represents the different time required from receiving an alarm to pushing it, and w represents the number of alarms that take x time.

7. The device for performing alarm stress testing based on JMeter simulation of dynamic environment equipment according to claim 6 is characterized in that: The alarm rules are as follows: add the required alarm rules to the alarm rule Gaoru template in advance, and import them into the acquisition and control system in batches during the stress test; when the alarm volume and alarm rule volume are large, check the average time of the complete process of pushing alarms to Kafka through the result file finally formed by the Python script.

8. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the method according to any one of claims 1 to 5 is implemented.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program for executing the method according to any one of claims 1 to 5.

Citation Information

Patent Citations

  • Performance test method, device and equipment for server cluster

    CN112486791A

  • Full-link monitoring method and device for monitoring alarm system

    CN113381884A