Intelligent link pressure measurement method and device supporting flexible scheduling
Through intelligent link pressure measurement methods that support flexible scheduling, dynamically filter and call links, distribute pressure measurement tasks, and monitor performance data in real time, the impact of full-link pressure measurement on system load and performance is solved, and the system is realized at different loads Stable and efficient operation under the
Patent Information
- Application Number
- CN202411586332.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-07
- Publication Date
- 2025-02-14
- Estimated Expiration
- 2044-11-07
AI Technical Summary
When evaluating system performance, full-link pressure testing may cause significant load on the system, affecting the user experience of normal users. In addition, high-load testing requires a large amount of computing and network resources, reducing the performance and reliability of the system.
Adopt intelligent link pressure measurement method that supports flexible scheduling, dynamically filter and call links, distribute pressure measurement tasks based on dynamic priority task scheduling algorithm, execute pressure measurement tasks under system load balancing conditions, and monitor performance data in real time for dynamic adjustment Pressure configuration parameters.
Perform pressure testing tasks under system load balancing, support distributed management of pressure testing tasks, and can modify pressure testing tasks according to pressure configuration parameters, fully cover performance tests from single point to distributed environments, and track business systems in real time key indicators, timely detect performance abnormalities and adjust task parameters, to ensure that the system remains stable and efficient under changing loads.
Smart Images

Figure CN119449680A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of full-link stress testing, and more specifically, to an intelligent link stress testing method and device supporting flexible scheduling. Background Art
[0002] Full-link stress testing is a process of stress testing the entire business chain (usually the core business chain) based on actual production business scenarios and production environments, simulating massive user requests and data, and continuously optimizing them. In response to increasingly complex business scenarios and massive data impacts, the availability, scalability, and fault tolerance of the entire business system are discovered and resolved.
[0003] Although full-link stress testing can effectively evaluate system performance, it also faces some significant challenges. It may cause significant load on the system, affecting the normal user experience. At the same time, high-load testing requires a lot of computing and network resources, which reduces the performance and reliability of the system.
[0004] Therefore, how to improve the performance and reliability of the system during the full-link stress testing process is an urgent problem that needs to be solved in this application. Summary of the invention
[0005] In view of this, the present application discloses an intelligent link stress testing method and device that supports flexible scheduling, aiming to ensure that the business system remains stable and efficient under constantly changing loads, thereby improving the stability and reliability of the system in actual use.
[0006] In order to achieve the above purpose, the disclosed technical solution is as follows:
[0007] In a first aspect, the present application discloses an intelligent link stress testing method supporting flexible scheduling, the method comprising:
[0008] When a call request is received, each call link corresponding to the call request is dynamically screened out from the preset call chain information;
[0009] Distribute stress testing tasks according to the dynamic priority task scheduling algorithm and the various call links; wherein the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks;
[0010] Execute the stress testing task under the condition of system load balancing;
[0011] During the execution of the stress testing task, the performance data of the stress testing task is monitored in real time;
[0012] The stress configuration parameters are dynamically adjusted according to the performance data to complete the full-link stress testing process.
[0013] Preferably, when a call request is received, each call link corresponding to the call request is dynamically screened out from preset call chain information, including:
[0014] When a call request is received, a corresponding tracking flag is assigned to the call request at a processing entry of the call request by an application; wherein the application is obtained by integrating a probe plug-in;
[0015] Passing the tracking flag to each processing link in sequence, so as to record log information corresponding to the tracking flag in each processing link;
[0016] Aggregating preset call chain information through a preset aggregation method; wherein the preset aggregation method at least includes an offline aggregation method and a real-time aggregation method;
[0017] According to the log information corresponding to the tracking flag, each call link corresponding to the call request is dynamically filtered out from the preset call chain information.
[0018] Preferably, the distribution of stress testing tasks according to the dynamic priority task scheduling algorithm and the various call links includes:
[0019] During the execution of the scheduling task, the link priority of each call link is calculated by a preset link priority calculation formula to obtain the priority score of each link and sort them;
[0020] Calculate the task priority of each call link by using a preset task priority calculation formula, obtain the priority score of each task and sort them;
[0021] According to the sorted link priority scores and the sorted task priority scores, load balancing degrees are calculated to obtain various load balancing degrees;
[0022] Calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable;
[0023] Determine the task and call link corresponding to the maximum value of the scheduling decision variable;
[0024] The tasks and call links corresponding to the maximum value of the scheduling decision variable are scheduled to the nodes corresponding to the tasks corresponding to the maximum value of the scheduling decision variable, and returned to the step of calculating the link priorities of the various call links by the preset link priority calculation formula during the execution of the scheduling task, obtaining the priority scores of each link and sorting them until the stress testing task distribution is completed.
[0025] Preferably, executing the stress testing task under the condition of system load balancing includes:
[0026] monitoring the pressure configuration parameters in real time;
[0027] When the stress configuration parameter reaches a preset threshold, a stress test target update mechanism is triggered;
[0028] Update stress configuration parameters through the stress test target update mechanism to ensure system load balancing;
[0029] Under the condition of system load balancing, the stress testing task is performed.
[0030] Preferably, in the process of executing the stress testing task, real-time monitoring of the performance data of the stress testing task includes:
[0031] During the local stress testing process, key indicators of the system are monitored in real time under simulation of different user behaviors and loads.
[0032] Launch edge computing stress testing tasks in the edge computing environment to simulate user access in different geographical locations;
[0033] In the process of executing the edge computing stress testing task, the performance indicators of the edge nodes are monitored in real time to ensure that the performance indicators accurately reflect the performance of the system under user access in different geographical locations.
[0034] Preferably, the process of dynamically adjusting the stress configuration parameters according to the performance data to complete the full-link stress test includes:
[0035] If the key indicators of the business system of the local stress test and the performance indicators of the edge nodes in the performance data are normal, the stress configuration parameters are dynamically adjusted according to the key indicators and performance indicators that are normal, and the local stress test results are obtained. The stress configuration parameters are dynamically adjusted according to the performance indicators of the edge nodes that are normal, and the edge stress test results are obtained to complete the full-link stress test process;
[0036] If the key indicators are monitored to be abnormal, the status of the local stress testing task is determined to be abnormal, and the problem is diagnosed and optimized for the key indicators with abnormalities;
[0037] If the performance indicator is monitored to be abnormal, the state of the edge stress testing task is determined to be abnormal, and the abnormal performance indicator is optimized;
[0038] According to the optimized key indicators and optimized performance indicators, the stress configuration parameters are dynamically adjusted to obtain the stress test results to complete the full-link stress test process.
[0039] Preferably, after dynamically adjusting the stress configuration parameters according to the performance data to complete the process of full-link stress testing, the method further includes:
[0040] Identify system performance bottlenecks and obtain identification results;
[0041] Compare the identification result with the local stress test result and the edge stress test result respectively to obtain an analysis result;
[0042] Develop and implement an optimization plan based on the analysis results.
[0043] The second aspect of the present application discloses an intelligent link stress testing device supporting flexible scheduling, the device comprising:
[0044] A dynamic screening unit, configured to dynamically screen out each call link corresponding to the call request from preset call chain information when a call request is received;
[0045] A distribution unit, used to distribute stress testing tasks according to a dynamic priority task scheduling algorithm and each call link; wherein the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks;
[0046] An execution unit, used to execute the stress testing task under the condition of system load balancing;
[0047] A real-time monitoring unit, used to monitor the performance data of the stress testing task in real time during the execution of the stress testing task;
[0048] The dynamic adjustment unit is used to dynamically adjust the stress configuration parameters according to the performance data to complete the full-link stress testing process.
[0049] Preferably, the dynamic screening unit comprises:
[0050] an allocation module, for allocating a corresponding tracking flag to the call request at a processing entry of the call request through an application when a call request is received; wherein the application is obtained through probe plug-in integration;
[0051] A transmission and recording module, used for sequentially transmitting the tracking flag to each processing link, so as to record log information corresponding to the tracking flag in each processing link;
[0052] An aggregation module, used to aggregate preset call chain information through a preset aggregation method; wherein the preset aggregation method at least includes an offline aggregation method and a real-time aggregation method;
[0053] A dynamic screening module is used to dynamically screen out various call links corresponding to the call request from the preset call chain information according to the log information corresponding to the tracking flag.
[0054] Preferably, the distribution unit comprises:
[0055] A first calculation module is used to calculate the link priority of each call link by a preset link priority calculation formula during the execution of the scheduling task, obtain the priority score of each link and sort them;
[0056] A second calculation module is used to calculate the task priority of each call link by using a preset task priority calculation formula, obtain the priority score of each task and sort it;
[0057] A third calculation module is used to calculate the load balancing degree according to the sorted link priority scores and the sorted task priority scores to obtain each load balancing degree;
[0058] A calculation and determination module, used to calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable;
[0059] A first determination module, used to determine the task and call link corresponding to the maximum value of the scheduling decision variable;
[0060] The scheduling module is used to schedule the tasks and call links corresponding to the maximum value of the scheduling decision variable to the nodes corresponding to the tasks corresponding to the maximum value of the scheduling decision variable, and return to the step of calculating the link priority of each call link by a preset link priority calculation formula during the execution of the scheduling task, obtaining the priority score of each link and sorting it until the stress testing task distribution is completed.
[0061] It can be seen from the above technical solution that the present application discloses an intelligent link stress testing method and device that supports flexible scheduling. When a call request is received, the call links corresponding to the call request are dynamically screened out from the preset call chain information, and the stress testing tasks are distributed according to the dynamic priority task scheduling algorithm and the various call links; wherein, the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks, and the stress testing tasks are executed under the condition of system load balancing. During the execution of the stress testing tasks, the performance data of the stress testing tasks are monitored in real time, and the stress configuration parameters are dynamically adjusted according to the performance data to complete the full-link stress testing process.
[0062] Through the above solution, under the condition of system load balancing, stress testing tasks are executed, distributed management of stress testing tasks is supported, and stress testing tasks can be modified according to the stress configuration parameters. In addition, by combining local stress testing and edge computing stress testing, performance testing from single point to distributed environments can be fully covered, key indicators of the business system can be tracked in real time, performance anomalies can be discovered in time, and task parameters can be adjusted to adapt to different environments and needs, so as to ensure that the business system remains stable and efficient under constantly changing loads, thereby improving the stability and reliability of the system in actual use. BRIEF DESCRIPTION OF THE DRAWINGS
[0063] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0064] Figure 1 A flow chart of an intelligent link stress testing method supporting flexible scheduling disclosed in an embodiment of the present application;
[0065] Figure 2 This is a schematic diagram of the low-intrusive JavaAgent probe technology disclosed in the embodiments of this application;
[0066] Figure 3 A flowchart of the stress testing task scheduling disclosed in the embodiment of this application;
[0067] Figure 4 A schematic diagram of the overall process of intelligent link stress testing supporting flexible scheduling disclosed in an embodiment of the present application;
[0068] Figure 5 A schematic diagram of the structure of an intelligent link stress testing device supporting flexible scheduling disclosed in an embodiment of the present application;
[0069] Figure 6 This is a schematic diagram of the structure of an electronic device disclosed in an embodiment of the present application. DETAILED DESCRIPTION
[0070] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0071] In this application, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.
[0072] As can be seen from the background technology, in the prior art, although full-link stress testing can effectively evaluate system performance, it also faces some significant challenges. It may cause a significant load on the system, affecting the user experience of normal users. At the same time, high-load testing requires a lot of computing and network resources, thereby reducing the performance and reliability of the system. Therefore, how to improve the performance and reliability of the system during the full-link stress testing process is a problem that this application urgently needs to solve.
[0073] In order to solve the above problems, the present application discloses an intelligent link stress testing method and device that supports flexible scheduling. Under the condition of system load balancing, stress testing tasks are executed, and distributed management of stress testing tasks is supported. Stress testing tasks can be modified according to stress configuration parameters, and through the combination of local stress testing and edge computing stress testing, performance testing from single point to distributed environment can be fully covered, key indicators of business systems can be tracked in real time, performance anomalies can be discovered in time, and task parameters can be adjusted to adapt to different environments and needs, so as to ensure that the business system remains stable and efficient under changing loads, thereby improving the stability and reliability of the system in actual use. The specific implementation method is specifically described through the following embodiments.
[0074] refer to Figure 1 As shown, an intelligent link stress testing method supporting flexible scheduling disclosed in an embodiment of the present application is disclosed. The intelligent link stress testing method supporting flexible scheduling mainly includes the following steps:
[0075] S101: When a call request is received, each call link corresponding to the call request is dynamically screened out from preset call chain information.
[0076] The preset call chain information is the entire call chain information obtained by aggregation through specific rules. The entire call chain information includes the call chain identifier (TraceId), call segment identifier (SpanId), parent span identifier (ParentSpanId), start time (StartTime), end time (EndTime), duration (Duration), service name (ServiceName), operation name (OperationName), log information (Log), tag information (Tags), error information (ErrorInformation), caller / callee information (Caller / Callee Information).
[0077] Through the above preset call chain information, the complete call process of a request from start to finish can be clearly observed, and then the call chains corresponding to the qualified call requests can be filtered out according to specific rules (such as links with response time exceeding 3 seconds and containing exceptions) to facilitate performance optimization and exception troubleshooting.
[0078] To facilitate understanding of the process of dynamically filtering out the call links corresponding to the call request from the preset call chain information when a call request is received, and automatically combing the call links by accessing the application probe and using the application probe to achieve zero intrusion into the business code, an example is given here to illustrate:
[0079] For example, the probe plug-in (JavaAgent) is integrated into the application. After the application is connected to the JavaAgent probe plug-in, when a call request is received, the probe assigns a TraceId to the request at the processing entrance of the call request, and passes this TraceId to the next processing link in turn. Logs are recorded in each processing link. Through this TraceId, the log information in the entire processing path from the start to the completion of the processing can be queried. After aggregation through specific rules (such as links with response time exceeding 3 seconds and containing exceptions), the entire call chain information can be obtained.
[0080] The principle of low-intrusion JavaAgent probe technology is as follows Figure 2 As shown. During the JVM initialization process, the bytecode file of the probe plug-in is loaded into the method area of the JVM, and the modified class is used to replace the original method used to implement database operations, cache operations, web containers, and RPC request sending in the business system, thereby achieving the purpose of adding full-link stress testing related functions without modifying the business code.
[0081] Figure 2 This paper shows a class loading and transformation process based on JavaAgent and ClassFileTransformer mechanism. The ClassFileTransformer mechanism is a core component in Java Agent technology, which is used to modify the bytecode of the class file before the JVM loads it.
[0082] 1. Agent injection: Figure 2 The Agent in is injected into the JVM and starts executing;
[0083] 2. Plugin loading: Agent loads plugins, which contain codes to implement specific functions, such as performance monitoring, logging, etc.
[0084] 3. Class loading request: The class in the application Jar package is requested to be loaded by the JVM. At this time, the ClassFileTransformerDispatcher will intercept the loading request;
[0085] 4. Class loading and transformation: ClassFileTransformerDispatcher modifies or enhances the class according to the loaded plug-in, and then loads the modified class bytecode into the JVM method area.
[0086] Specifically, when a call request is received, the process of dynamically filtering out the call links corresponding to the call request from the preset call chain information is shown in A1-A4:
[0087] A1: When a call request is received, a corresponding tracking flag is allocated to the call request at a processing entry of the call request through an application; wherein the application is obtained through probe plug-in integration.
[0088] A2: The tracking flag is passed to each processing link in sequence, so as to record log information corresponding to the tracking flag in each processing link.
[0089] Among them, each processing link represents each processing link from the start of the call to the end of the call.
[0090] A3: Aggregate the preset call chain information (the entire call chain information) through a preset aggregation method; wherein the preset aggregation method at least includes an offline aggregation method and a real-time aggregation method.
[0091] The preset call chain information is used to query the log information corresponding to the tracking flag recorded in each processing link. The log information corresponding to the tracking flag is the log information of the complete call process of the call request from the start of the call to the end of the call.
[0092] The specific preset aggregation methods are as follows:
[0093] Before each stress test, the global topology data is accurately calculated using offline aggregation, that is, the topology map is periodically generated according to a set of pre-defined aggregation rules.
[0094] It should be noted that the aggregation rules are customized by the user in combination with business characteristics. For example, a certain order interface can be further subdivided into clothing, accessories or digital products according to the product category. During the optimization process, real-time aggregation is used to dynamically filter the call chain and generate a topology map according to the query conditions specified by the user. For example, the system filters out the call links with a response time of more than 3 seconds from the call chain data in all call links based on the query conditions (such as checking the call chains with a response time of more than 3 seconds and containing exceptions), and then searches for links containing abnormal calls from these filtered call links. If the number of links finally filtered out exceeds 5,000, the system will select the first 5,000 for processing and generate the corresponding topology map. This is because when the amount of detailed data of the call chain that meets the conditions exceeds a certain threshold, the real-time aggregation computing node may be blown up. Therefore, the upper limit of the number of aggregated links in this application can preferably be set to 5,000.
[0095] Among them, the response time, number of links, threshold, and upper limit of the number of aggregation links are set according to actual conditions, and this application does not make specific limitations.
[0096] A4: According to the log information corresponding to the trace flag, filter out the call links corresponding to the call request from the preset call chain information.
[0097] Among them, the log information corresponding to the tracking flag records the information of each call link.
[0098] In A4, according to the query condition (viewing call chains with a response time exceeding 3 seconds and containing exceptions), according to the information of each call link recorded in the log information corresponding to the tracking flag, the call chain data in all call links are filtered out to select each call link with a response time of the call request exceeding 3 seconds.
[0099] Automatically sort out each call link, and through bytecode enhancement technology, dynamically modify the code when the Java virtual machine (JVM) loads the public component library, achieving zero intrusion into the business code.
[0100] In the process of automatically combing each call link, there are two tasks, one is to access the application probe, and the other is to automatically comb the call link through the application probe. Specifically, it is achieved by accessing the application probe and automatically combing the call link through the application probe.
[0101] S102: Distribute stress testing tasks according to a dynamic priority task scheduling algorithm and various call links; wherein the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks.
[0102] In S102, a stress testing task is defined in a task scheduling system, and the stress testing task is distributed based on a dynamic priority scheduling algorithm and various call links.
[0103] Defining stress testing tasks includes defining performance indicators, formulating test scenarios, and setting stress testing goals.
[0104] Performance indicators include response time (page loading time, request response time), throughput, number of concurrent users, system stability, etc.
[0105] This application sets up four load test scenarios, namely normal load, high load, peak load and continuous load. The stress test objectives include service level agreements (SLAs) (SLAs set response time requirements for key operations) and performance benchmarks (setting performance requirements for the system under different load conditions).
[0106] For newly launched systems, this application requires performance engineers, business teams, etc. to collaborate to set stress testing targets. For systems in operation, this application uses automated monitoring tools to continuously track system performance and updates stress testing targets based on real-time data. Specifically, at the beginning of the operation of the system, performance engineers and the business team jointly discuss and set initial stress testing targets. As the system in operation runs, the monitoring tool Grafana collects system performance data in real time. When the monitoring indicator reaches or exceeds the set threshold (the threshold is set according to the actual situation and is not specifically limited in this application), the stress testing target update mechanism is triggered to dynamically adjust the stress testing target.
[0107] Dynamically adjusting stress testing targets includes, but is not limited to, increasing or decreasing load targets, adjusting response time requirements, and modifying throughput targets.
[0108] The specific process of stress testing task distribution is based on the dynamic priority task scheduling algorithm and each call link, such as Figure 3 and B1-B6.
[0109] exist Figure 3 , calculate and sort the link priorities of each call link;
[0110] Calculate and sort the task priorities of each call link;
[0111] Calculate the load balancing degree according to the link priority of each call link after sorting and the task priority of each call link after sorting;
[0112] Calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable;
[0113] Determine the tasks and call links corresponding to the maximum value of the scheduling decision variable, and perform task scheduling;
[0114] Determine whether it is the last task;
[0115] If yes, the stress testing task distribution process ends;
[0116] If not, return to the step of calculating the link priority of each call link and sorting it until all tasks in the stress testing task are distributed.
[0117] To facilitate understanding of the process of stress testing task distribution based on the dynamic priority task scheduling algorithm and various call links, an example is given here:
[0118] During the "Double Eleven" promotion, an e-commerce platform needs to perform full-link stress testing to ensure the stability and performance of the system under high traffic conditions. The following are the specific implementation steps of task scheduling:
[0119] Scenario setting: Link 1, user login; Link 2, product browsing; Link 3, shopping cart operation. Task 1, user login function test; Task 2, product loading performance test; Task 3, shopping cart product addition test;
[0120] Data settings:
[0121] Link 1: W d =0.5,W th =0.3,W b =0.1,W p =0.1;
[0122] Link 2: W d =0.4,W th =0.4,W b =0.2,W p =0.0;
[0123] Link 3: W d =0.3,W th =0.3,W b =0.4,W p =0.0;
[0124] Mission 1: W f =0.5,W r =0.4,W t =0.1,W c =0.0;
[0125] Mission 2: W f =0.4,W r =0.4,W t =0.2,W c =0.0;
[0126] Mission 3: W f =0.4,W r =0.4,W t =0.2,W c =0.0;
[0127] 1. Calculate link priority:
[0128] Link 1 score: L1 = W d ·S d +W th ·S th +W b ·S b +W p ·S p =0.5×0.9+0.3×0.8+0.1×0.7+0.1×0.6=0.81;
[0129] Link 2 score: L2 = W d ·S d +W th ·S th +W b ·S b +W p ·S p =0.4×0.9+0.4×0.7+0.2×0.8+0.0×0.6=0.77;
[0130] Link 3 score: L3 = W d ·S d +W th ·S th +W b ·S b +W p ·S p =0.3×0.8+0.3×0.9+0.4×0.8+0.0×0.4=0.82;
[0131] Next, normalize the link priority:
[0132] L max =0.82, L min =0.77;
[0133]
[0134] The normalized link priorities are ranked as follows: link 3 > link 1 > link 2.
[0135] 2. Calculate task priority:
[0136] Set the weight factors α = 0.7, β = 0.3, and the average task processing time Task 1(t wait =0,t left =15) Score:
[0137] T 1_1 =W f ·S f +W r ·S r +W t ·S t +W c ·S c =0.5×0.9+0.4×0.8+0.1×0.6+0.0×0.7=0.77;
[0138]
[0139] Task 2 (t wait =10,t left=10) Score:
[0140] T 1_2 =W f ·S f +W r ·S r +W t ·S t +W c ·S c =0.4×0.8+0.4×0.6+0.2×0.7+0.0×0.9=0.73;
[0141] Task 3 (t wait =20,t left =20) Score:
[0142] T 1_3 =W f ·S f +W r ·S r +W t ·S t +W c ·S c =0.4×0.9+0.4×0.8+0.2×0.7+0.0×0.9=0.82;
[0143]
[0144] Next, normalize the task priorities:
[0145] L max =0.82, L min =0.73;
[0146]
[0147] The final score of Task 1 is: T = αT 1_1,normalized +βT 2_1 =0.7×0.44+0.3×0≈0.31;
[0148] Final score for Task 2: T = αT 1_2,normalized +βT 2_2 =0.7×0+0.3×1=0.3;
[0149] Final score for Task 3: T = αT 1_3,normalized +βT 2_3 =0.7×1+0.3×0.5=0.85;
[0150] Sort the normalized character priorities as follows: Task 3 > Task 1 > Task 2;
[0151] 3. Load balancing calculation:
[0152] Assuming node load:
[0153] Node 1:50;
[0154] Node 2: 70;
[0155] Node 3:60;
[0156] Assuming the task load:
[0157] Task 1:10;
[0158] Task 2:20;
[0159] Mission 3:15;
[0160] Assumptions:
[0161] Task 1 is assigned to node 1;
[0162] Task 2 is assigned to node 2;
[0163] Task 3 is assigned to node 3;
[0164] New load of node 1: L 1_new =60;
[0165] New load of node 2: L 2_new =90;
[0166] New load of node 3: L 3_new =75;
[0167] LB max =90;
[0168]
[0169]
[0170] 4. Calculate scheduling decision variables:
[0171]
[0172] 5. Scheduling:
[0173] Schedule task 3 to node 3 for execution.
[0174] 6. Judgment:
[0175] This is not the last task, so return to step 1 to calculate the link priority and recalculate it, starting a new cycle.
[0176] B1: During the execution of the scheduling task, the link priority of each call link is calculated using a preset link priority calculation formula to obtain the priority score of each link and sort them.
[0177] In B1, the normalized link priority score is calculated using a preset link priority calculation formula. The preset link priority calculation formula is shown in formula (1).
[0178]
[0179] Among them, L normalized is the normalized link priority score; L max is the maximum priority score of the link; L min is the minimum priority score of the link; L is the priority score of the link, and the calculation formula of L is shown in formula (2).
[0180] L=W d ×S d +W th ×S th +W b ×S b +W P ×S p (2)
[0181] Among them, W d is the weight of the dependency; S d is the dependency score (0-1); W th is the traffic size weight; S th W is the traffic size score (0-1); b is the business importance weight; S b W is the business importance score (0-1); P is the performance impact weight; S p Score the performance impact (0-1).
[0182] B2: Calculate the task priority of each call link using the preset task priority calculation formula, obtain the priority score of each task and sort it.
[0183] The preset task priority calculation formula is shown in formula (3).
[0184] T=αT 1_normalized +βT2(3)
[0185] Where T is the preset task priority; T 1_normalized is the normalized priority score of the task; α is T 1_normalized The weight factor of ; T2 is the task urgency; β is the weight factor of T2.
[0186] T1_normalized The calculation formula is shown in formula (4).
[0187]
[0188] Among them, T1 is the priority score of the task; T max is the maximum priority score of the task; T min The minimum priority score for a task.
[0189] The calculation formula of T1 is shown in formula (5).
[0190] T1=W f ×S f +W r ×S r +W t ×S t +W c ×S c (5)
[0191] Among them, W f is the functional weight; S f is the functional test score (0-1); W r is the risk weight; S r is the risk score (0-1); W t is the time sensitivity weight; S t Score for time (0-1); W c is the complexity weight; S c Score the complexity (0-1).
[0192] The expression of T2 is shown in formula (6).
[0193]
[0194] Among them, t wait is the waiting time for the current task; t left The remaining time for the task; is the average task processing time.
[0195] B3: Perform load balancing calculation based on the sorted link priority scores and the sorted task priority scores to obtain various load balancing degrees.
[0196] Among them, each load balancing degree is the load balancing degree of the system when all nodes corresponding to each call link join the task.
[0197] According to the sorted link priority scores and the sorted task priority scores, the load balancing degree of the system when all nodes corresponding to each link join the task is calculated.
[0198] The specific expression of load balancing degree is shown in formula (7).
[0199]
[0200] Among them, LB is the load balancing degree; L max is the load value of the node with the largest load among all nodes; L ij is the load value of the jth node of the i-th task; the closer the load balancing degree is to 1, the better the load balancing is.
[0201] B4: Calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable.
[0202] The specific formula for calculating the scheduling decision variables is shown in formula (8).
[0203]
[0204] Among them, λ ij is the scheduling decision variable; LB ij is the link priority of the jth node of the ith task; T ij is the task priority of the jth node of the ith task; L ij is the load balancing degree of the jth node of the i-th task.
[0205] B5: Determine the tasks and call links corresponding to the maximum value of the scheduling decision variable.
[0206] B6: Schedule the tasks and call links corresponding to the maximum value of the scheduling decision variable to the node corresponding to the task corresponding to the maximum value of the scheduling decision variable, and return to the step of calculating the link priority of each call link by the preset link priority calculation formula during the execution of the scheduling task, obtaining the priority score of each link and sorting it until the stress test task distribution is completed.
[0207] S103: Execute the stress testing task under the condition of system load balancing.
[0208] Specifically, under the condition of system load balancing, the process of executing the stress testing task is shown in C1-C4.
[0209] C1: Real-time monitoring of pressure configuration parameters.
[0210] Among them, all stress configuration parameters are stored in the configuration management system. The stress configuration parameters are pre-configured and then dynamically adjusted according to the performance data collected during the stress test.
[0211] It should be noted that the configuration management system is used to store and manage the stress configuration parameters of the stress testing task, so that these parameters can be dynamically adjusted when the task is running. The stress configuration parameters specifically include the number of concurrent users, request frequency, request timeout, load mode test duration, etc.
[0212] C2: When the stress configuration parameter reaches the preset threshold, the stress test target update mechanism is triggered.
[0213] Different pressure configuration parameters have different corresponding preset thresholds, which are set according to actual conditions and are not specifically limited in this application.
[0214] The stress test target update mechanism refers to dynamically adjusting the test target based on the feedback information collected during the test to ensure that the test results can accurately reflect the performance of the system under actual load.
[0215] The stress testing target update mechanism usually includes the following steps:
[0216] 1. Set initial goals: Before starting stress testing, set a set of initial test goals, which may include performance indicators such as throughput, response time, and error rate;
[0217] 2. Collect feedback information: During the test process, monitor the system's performance indicators and collect feedback information. This feedback information can come from system logs, monitoring tools, performance testing tools, etc.
[0218] 3. Analyze feedback information: Analyze the collected feedback information to determine whether the current test results meet expectations. If not, find out the reasons;
[0219] 4. Adjust test objectives: Adjust test objectives based on analysis results. This may require increasing or decreasing test loads or changing test strategies.
[0220] 5. Re-execute the test: Re-execute the stress test according to the adjusted test objectives until the expected performance indicators are achieved;
[0221] 6. Continuous monitoring and optimization: After the test is completed, continuously monitor the system performance and optimize it according to the actual situation to ensure that the system can run stably under the actual load.
[0222] C3: Update stress configuration parameters through the stress test target update mechanism to ensure system load balancing.
[0223] In C3, the stress configuration parameters are dynamically adjusted according to the feedback information (stress test target) to achieve the corresponding load mode. For example, monitor the average response time. If it exceeds the preset threshold, you may need to reduce the number of users or request frequency; monitor the failure rate of requests. If the error rate exceeds 1%, you need to reduce the number of concurrency or request frequency; observe the usage of CPU, memory, and network bandwidth. If an indicator is close to 100%, you should consider reducing the load.
[0224] C4: Perform stress testing tasks under the condition of system load balancing.
[0225] In C4, under the condition of system load balancing, local stress testing tasks and edge computing stress testing tasks are started as planned to ensure coverage of different test scenarios. During the execution of stress testing tasks, stress is applied according to the parameters in the configuration management system.
[0226] S104: During the execution of the stress testing task, the performance data of the stress testing task is monitored in real time.
[0227] You can use monitoring tools to track the execution status and performance data of stress testing tasks in real time, and adjust task parameters through the configuration management system when necessary.
[0228] Specifically, during the execution of the stress testing task, the process of real-time monitoring of the performance data of the stress testing task is shown in D1-D3.
[0229] D1: During the execution of local stress testing tasks, key indicators of the system are monitored in real time under simulation of different user behaviors and loads.
[0230] It should be noted that the local stress testing task is used to simulate the internal load of the system.
[0231] Key indicators under load include the response time, throughput, CPU and memory usage of the local stress tested business system.
[0232] For local stress testing tasks, after starting the local stress testing task, you need to observe the performance of the system under simulated different user behaviors and loads to ensure that the stress testing tool has successfully started the test according to the preset scenario. For example, the number of concurrent users and request frequency should meet the setting requirements. Use system monitoring tools (such as Grafana) to track key indicators such as the system's response time, throughput, CPU and memory usage in real time. At the same time, pay close attention to whether there are performance degradations or errors, such as increased response delays or system crashes. If anomalies are found, detailed information needs to be recorded for subsequent problem diagnosis and optimization.
[0233] D2: Start the edge computing stress testing task in the edge computing environment to simulate user access in different geographical locations.
[0234] It should be noted that edge computing stress testing tasks are used to simulate real user experience.
[0235] For edge computing stress testing tasks, start edge computing stress testing tasks in the edge computing environment to simulate user access from different geographical locations. Ensure that the test covers major regions across the country and evaluate the performance of the system under different network conditions.
[0236] Real-time monitoring of performance data such as edge node response time, network latency, and failure rate ensures that these data accurately reflect the performance of the system under actual national user access. By analyzing these data, the performance of the system in different geographical locations and network environments can be evaluated, possible network bottlenecks or geographical distribution issues can be identified, and necessary optimization can be performed.
[0237] D3: When performing edge computing stress testing tasks, the performance indicators of edge nodes are monitored in real time to ensure that the performance indicators accurately reflect the performance of the system under user access in different geographical locations.
[0238] After ensuring that the local stress testing tasks and the test scenarios in the edge computing environment are executed effectively, it is necessary to check the execution logs of the task scheduling system and the stress testing tool to confirm whether each task is executed smoothly according to the predetermined plan and parameters. At the same time, verify the report generated by the stress testing tool to ensure that all predetermined test scenarios and parameters are executed correctly.
[0239] S105: Dynamically adjust stress configuration parameters according to performance data to complete the full-link stress testing process.
[0240] Specifically, the stress configuration parameters are dynamically adjusted according to the performance data to complete the full-link stress testing process, as shown in E1-E4.
[0241] E1: If the key indicators of the business system and the performance indicators of the edge nodes in the local stress test in the performance data are normal, the stress configuration parameters are dynamically adjusted according to the key indicators and performance indicators that are normal to obtain the local stress test results. The stress configuration parameters are dynamically adjusted according to the performance indicators of the edge nodes that are normal to obtain the edge stress test results to complete the full-link stress test process.
[0242] Among them, local stress testing results usually focus on the performance in the development and testing stages, mainly focusing on the performance of the system in the development machine or test environment.
[0243] The local stress test results mainly include response time, throughput, CPU and memory usage, etc.
[0244] The edge stress test results focus on performance in the edge computing environment, especially the latency, errors, and resource usage when handling real user requests.
[0245] Edge stress testing results mainly include response time, throughput, error rate, network latency, resource utilization, user experience indicators, geographic distribution data, etc.
[0246] E2: If an abnormality is detected in a key indicator, the status of the local stress testing task is determined to be abnormal, and the problem is diagnosed and optimized for the abnormal key indicator.
[0247] E3: If an abnormal performance indicator is detected, the edge stress testing task is determined to be in an abnormal state, and the abnormal performance indicator is optimized.
[0248] E4: According to the optimized key indicators and optimized performance indicators, dynamically adjust the stress configuration parameters to obtain the stress test results (local stress test results and edge stress test results) to complete the full-link stress test process.
[0249] During the full-link stress testing process, parameters are dynamically adjusted through the configuration management system based on monitoring data and actual needs.
[0250] The specific steps are as follows: Configure monitoring tools, such as Grafana monitoring tools, and use Grafana monitoring tools to monitor key indicators of the system, including resource usage, response time, and error rate. Set up monitoring panels and alarm mechanisms to ensure that data can be acquired and analyzed in real time, and receive timely notifications when performance anomalies occur. Based on the results of real-time data analysis, determine whether task parameters need to be adjusted, and make necessary updates through the configuration management system to ensure that parameter adjustments can take effect immediately and improve system performance.
[0251] After dynamically adjusting the stress configuration parameters according to the performance data to complete the full-link stress test process, collect and analyze the local stress test results and edge stress test results, identify the system performance bottlenecks, and perform corresponding optimizations. Specifically, identify the system performance bottlenecks, obtain the identification results, compare the identification results with the local stress test results and edge stress test results, obtain the analysis results, and formulate and implement the optimization plan based on the analysis results.
[0252] Among them, the analysis results are used to evaluate the performance of business systems in different environments.
[0253] After the stress test task is completed, it is crucial to collect and analyze the test data. Obtain comprehensive test data from the stress test tool and monitoring system, including indicators such as response time, throughput, and system load. Use data analysis tools to conduct in-depth analysis of the data, identify performance bottlenecks in the system, and compare the test results of the local stress test task with the test results in the edge computing environment to evaluate the performance of the system in different environments, obtain analysis results, and formulate and implement optimization plans based on the analysis results, such as adjusting the system configuration or optimizing the code. Finally, re-execute the stress test to verify the optimization effect and ensure that the system performance is effectively improved.
[0254] In order to facilitate the understanding of the process of the intelligent link stress testing method that supports flexible scheduling, combined with Figure 4 Let's take an example:
[0255] Figure 4 In step S1, the links are automatically combed, and the code is dynamically modified when the JVM loads the public component library through bytecode enhancement technology, so as to achieve zero intrusion on the business code;
[0256] Step S2, defining stress testing tasks in the task scheduling system, and distributing tasks based on a dynamic priority scheduling algorithm;
[0257] Step S3, storing all pressure configuration parameters in a configuration management system for dynamic adjustment;
[0258] Step S4: Execute local stress testing and edge computing stress testing tasks as planned to ensure coverage of different test scenarios.
[0259] Step S5: Use monitoring tools to track the execution status and performance data of the stress testing task in real time. During the execution of the stress testing task, dynamically adjust parameters through the configuration management system according to the performance data and actual needs.
[0260] Step S6, collect and analyze local stress test results and edge stress test results, identify system performance bottlenecks, and perform corresponding optimizations.
[0261] This application has the following technical advantages:
[0262] (1) Flexible scheduling of stress testing tasks, support for distributed management of stress testing tasks, and the ability to modify stress testing tasks based on stress configuration parameters;
[0263] (2) The combination of local stress testing and edge computing stress testing can comprehensively cover performance testing from single point to distributed environments, ensuring that the system can run stably under various load and geographical conditions;
[0264] (3) It can track the key indicators of the system in real time, detect performance anomalies in a timely manner, and adjust task parameters to ensure that the system remains stable and efficient under changing loads;
[0265] (4) In the iterative optimization process, the system performance can be continuously improved to adapt to different environments and requirements, ensuring the stability and reliability of the system in actual use;
[0266] The beneficial effects of the embodiments of the present application are as follows: under the condition of system load balancing, stress testing tasks are executed, distributed management of stress testing tasks is supported, and the stress testing tasks can be modified according to the stress configuration parameters. Moreover, through the combination of local stress testing and edge computing stress testing, performance testing from single point to distributed environments can be fully covered, key indicators of the business system can be tracked in real time, performance anomalies can be discovered in time and task parameters can be adjusted to adapt to different environments and needs, so as to ensure that the business system remains stable and efficient under constantly changing loads, thereby improving the stability and reliability of the system in actual use.
[0267] Based on the above embodiments Figure 1 A smart link stress testing method supporting flexible scheduling is disclosed. The embodiment of the present application also discloses a smart link stress testing device supporting flexible scheduling, specifically as follows Figure 5 As shown, the intelligent link stress testing device supporting flexible scheduling includes:
[0268] The dynamic screening unit 501 is used to dynamically screen out the call links corresponding to the call request from the preset call chain information when receiving the call request;
[0269] A distribution unit 502 is used to distribute stress testing tasks according to a dynamic priority task scheduling algorithm and various call links; wherein the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks;
[0270] The execution unit 503 is used to execute the stress testing task under the condition of system load balancing;
[0271] A real-time monitoring unit 504 is used to monitor the performance data of the stress testing task in real time during the execution of the stress testing task;
[0272] The dynamic adjustment unit 505 is used to dynamically adjust the stress configuration parameters according to the performance data to complete the full-link stress testing process.
[0273] Furthermore, the dynamic screening unit 501 includes:
[0274] an allocation module, for allocating a corresponding tracking flag to the call request at a processing entry of the call request through an application when a call request is received; wherein the application is obtained through the probe plug-in integration;
[0275] A transfer recording module is used to sequentially transfer the tracking flag to each processing link, so as to record the log information corresponding to the tracking flag in each processing link;
[0276] An aggregation module, used to aggregate preset call chain information through a preset aggregation method; wherein the preset aggregation method includes at least an offline aggregation method and a real-time aggregation method;
[0277] The dynamic screening module is used to dynamically screen out the call links corresponding to the call request from the preset call chain information according to the log information corresponding to the tracking flag.
[0278] Furthermore, the distribution unit 502 includes:
[0279] The first calculation module is used to calculate the link priority of each call link by using a preset link priority calculation formula during the execution of the scheduling task, obtain the priority score of each link and sort them;
[0280] The second calculation module is used to calculate the task priority of each call link by using a preset task priority calculation formula, obtain the priority score of each task and sort it;
[0281] A third calculation module is used to calculate the load balancing degree according to the sorted link priority scores and the sorted task priority scores to obtain each load balancing degree;
[0282] A calculation and determination module is used to calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable;
[0283] A first determination module is used to determine the task and call link corresponding to the maximum value of the scheduling decision variable;
[0284] The scheduling module is used to schedule the tasks and call links corresponding to the maximum value of the scheduling decision variable to the nodes corresponding to the tasks corresponding to the maximum value of the scheduling decision variable, and return to the step of calculating the link priority of each call link through the preset link priority calculation formula during the execution of the scheduling task, obtaining the priority score of each link and sorting it until the stress testing task distribution is completed.
[0285] Furthermore, the execution unit 503 includes:
[0286] A first real-time monitoring module, used for real-time monitoring of pressure configuration parameters;
[0287] The trigger module is used to trigger the stress test target update mechanism when the stress configuration parameter reaches the preset threshold;
[0288] The update module is used to update the stress configuration parameters through the stress test target update mechanism to ensure system load balancing;
[0289] The execution module is used to execute stress testing tasks under the condition of system load balancing.
[0290] Furthermore, the real-time monitoring unit 504 includes:
[0291] The second real-time monitoring module is used to monitor the key indicators of the system in real time under simulation of different user behaviors and loads during the execution of local stress testing tasks;
[0292] The startup module is used to start the edge computing stress testing task in the edge computing environment to simulate user access in different geographical locations;
[0293] The third real-time monitoring module is used to monitor the performance indicators of edge nodes in real time during the execution of edge computing stress testing tasks to ensure that the performance indicators accurately reflect the performance of the system under user access in different geographical locations.
[0294] Furthermore, the dynamic adjustment unit 505 includes:
[0295] The first dynamic adjustment module is used to dynamically adjust the stress configuration parameters according to the key indicators and performance indicators of the business system of the local stress test and the performance indicators of the edge nodes in the performance data, if there are no abnormalities, to obtain the local stress test results, and dynamically adjust the stress configuration parameters according to the performance indicators of the edge nodes without abnormalities to obtain the edge stress test results, so as to complete the full-link stress test process;
[0296] The second determination module is used to determine that the status of the local stress testing task is abnormal if an abnormality is detected in the key indicator, and to diagnose and optimize the key indicator with the abnormality;
[0297] The third determination module is used to determine that the state of the edge stress testing task is an abnormal state if an abnormal performance indicator is monitored, and optimize the abnormal performance indicator;
[0298] The second dynamic adjustment module is used to dynamically adjust the stress configuration parameters according to the optimized key indicators and the optimized performance indicators to obtain the stress test results to complete the full-link stress test process.
[0299] Furthermore, the intelligent link stress testing device supporting flexible scheduling also includes:
[0300] An identification unit, used to identify system performance bottlenecks and obtain identification results;
[0301] A comparison unit, used to compare the recognition result with the local stress test result and the edge stress test result respectively to obtain an analysis result;
[0302] The formulation unit is used to formulate and implement optimization plans based on the analysis results.
[0303] The embodiment of the present application provides an intelligent link stress testing device that supports flexible scheduling, so that the system can maintain high efficiency and stability under different environments and loads, while having flexible task management and powerful error handling capabilities, thereby improving the performance and reliability of the system as a whole.
[0304] The beneficial effects of the embodiments of the present application are as follows: under the condition of system load balancing, stress testing tasks are executed, distributed management of stress testing tasks is supported, and the stress testing tasks can be modified according to the stress configuration parameters. Moreover, through the combination of local stress testing and edge computing stress testing, performance testing from single point to distributed environments can be fully covered, key indicators of the business system can be tracked in real time, performance anomalies can be discovered in time and task parameters can be adjusted to adapt to different environments and needs, so as to ensure that the business system remains stable and efficient under constantly changing loads, thereby improving the stability and reliability of the system in actual use.
[0305] An embodiment of the present application further provides a storage medium, which includes stored instructions, wherein when the instructions are executed, the device where the storage medium is located is controlled to execute the intelligent link stress testing method supporting flexible scheduling as described above.
[0306] The present application also provides an electronic device, whose structural diagram is as follows: Figure 6 As shown, it specifically includes a memory 601 and one or more instructions 602, wherein the one or more instructions 602 are stored in the memory 601 and are configured to be executed by one or more processors 603 to execute the one or more instructions 602 to execute the above-mentioned intelligent link stress testing method supporting flexible scheduling.
[0307] For the aforementioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the order of the actions described, because according to the present application, some steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present application.
[0308] It should be noted that each embodiment in this specification is described in a progressive manner, and each embodiment focuses on the differences from other embodiments, and the same or similar parts between the embodiments can be referred to each other. For the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.
[0309] The steps in the methods of the embodiments of the present application can be adjusted in order, combined, and deleted according to actual needs.
[0310] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are merely used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations.
[0311] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.
[0312] The above is only a preferred implementation of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
Claims
1. An intelligent link stress testing method supporting flexible scheduling, characterized in that: The method comprises: When a call request is received, each call link corresponding to the call request is dynamically screened out from the preset call chain information; Distribute stress testing tasks according to the dynamic priority task scheduling algorithm and the various call links; wherein the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks; Execute the stress testing task under the condition of system load balancing; During the execution of the stress testing task, the performance data of the stress testing task is monitored in real time; The stress configuration parameters are dynamically adjusted according to the performance data to complete the full-link stress testing process.
2. The method according to claim 1, characterized in that When a call request is received, each call link corresponding to the call request is dynamically screened from preset call chain information, including: When a call request is received, a corresponding tracking flag is assigned to the call request at a processing entry of the call request by an application; wherein the application is obtained by integrating a probe plug-in; Passing the tracking flag to each processing link in sequence, so as to record log information corresponding to the tracking flag in each processing link; Aggregating preset call chain information through a preset aggregation method; wherein the preset aggregation method at least includes an offline aggregation method and a real-time aggregation method; According to the log information corresponding to the tracking flag, each call link corresponding to the call request is dynamically filtered out from the preset call chain information.
3. The method according to claim 1, characterized in that The stress testing task distribution according to the dynamic priority task scheduling algorithm and the various call links includes: During the execution of the scheduling task, the link priority of each call link is calculated by a preset link priority calculation formula to obtain the priority score of each link and sort them; Calculate the task priority of each call link by using a preset task priority calculation formula, obtain the priority score of each task and sort them; According to the sorted link priority scores and the sorted task priority scores, load balancing degrees are calculated to obtain various load balancing degrees; Calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable; Determine the task and call link corresponding to the maximum value of the scheduling decision variable; The tasks and call links corresponding to the maximum value of the scheduling decision variable are scheduled to the nodes corresponding to the tasks corresponding to the maximum value of the scheduling decision variable, and returned to the step of calculating the link priorities of the various call links by the preset link priority calculation formula during the execution of the scheduling task, obtaining the priority scores of each link and sorting them until the stress testing task distribution is completed.
4. The method according to claim 1, characterized in that The step of executing the stress testing task under the condition of system load balancing includes: monitoring the pressure configuration parameters in real time; When the stress configuration parameter reaches a preset threshold, a stress test target update mechanism is triggered; Update stress configuration parameters through the stress test target update mechanism to ensure system load balancing; Under the condition of system load balancing, the stress testing task is performed.
5. The method according to claim 1, characterized in that During the execution of the stress testing task, real-time monitoring of the performance data of the stress testing task includes: During the local stress testing process, key indicators of the system are monitored in real time under simulation of different user behaviors and loads. Launch edge computing stress testing tasks in the edge computing environment to simulate user access in different geographical locations; In the process of executing the edge computing stress testing task, the performance indicators of the edge nodes are monitored in real time to ensure that the performance indicators accurately reflect the performance of the system under user access in different geographical locations.
6. The method according to claim 5, characterized in that The process of dynamically adjusting the stress configuration parameters according to the performance data to complete the full-link stress test includes: If the key indicators of the business system of the local stress test and the performance indicators of the edge nodes in the performance data are normal, the stress configuration parameters are dynamically adjusted according to the key indicators and performance indicators that are normal, and the local stress test results are obtained. The stress configuration parameters are dynamically adjusted according to the performance indicators of the edge nodes that are normal, and the edge stress test results are obtained to complete the full-link stress test process; If the key indicators are monitored to be abnormal, the status of the local stress testing task is determined to be abnormal, and the problem is diagnosed and optimized for the key indicators with abnormalities; If the performance indicator is monitored to be abnormal, the state of the edge stress testing task is determined to be abnormal, and the abnormal performance indicator is optimized; According to the optimized key indicators and optimized performance indicators, the stress configuration parameters are dynamically adjusted to obtain the stress test results to complete the full-link stress test process.
7. The method according to claim 1, characterized in that After dynamically adjusting the stress configuration parameters according to the performance data to complete the full-link stress test process, the process further includes: Identify system performance bottlenecks and obtain identification results; Compare the identification result with the local stress test result and the edge stress test result respectively to obtain an analysis result; Develop and implement an optimization plan based on the analysis results.
8. An intelligent link stress testing device supporting flexible scheduling, characterized in that: The device comprises: A dynamic screening unit, configured to dynamically screen out each call link corresponding to the call request from preset call chain information when a call request is received; A distribution unit, used to distribute stress testing tasks according to a dynamic priority task scheduling algorithm and each call link; wherein the stress testing tasks include at least local stress testing tasks and edge computing stress testing tasks; An execution unit, used to execute the stress testing task under the condition of system load balancing; A real-time monitoring unit, used to monitor the performance data of the stress testing task in real time during the execution of the stress testing task; The dynamic adjustment unit is used to dynamically adjust the stress configuration parameters according to the performance data to complete the full-link stress testing process.
9. The device according to claim 8, characterized in that The dynamic screening unit comprises: an allocation module, for allocating a corresponding tracking flag to the call request at a processing entry of the call request through an application when a call request is received; wherein the application is obtained through probe plug-in integration; A transmission and recording module, used for sequentially transmitting the tracking flag to each processing link, so as to record log information corresponding to the tracking flag in each processing link; An aggregation module, used to aggregate preset call chain information through a preset aggregation method; wherein the preset aggregation method at least includes an offline aggregation method and a real-time aggregation method; A dynamic screening module is used to dynamically screen out various call links corresponding to the call request from the preset call chain information according to the log information corresponding to the tracking flag.
10. The device according to claim 8, characterized in that The distribution unit comprises: A first calculation module is used to calculate the link priority of each call link by a preset link priority calculation formula during the execution of the scheduling task, obtain the priority score of each link and sort them; A second calculation module is used to calculate the task priority of each call link by using a preset task priority calculation formula, obtain the priority score of each task and sort it; A third calculation module is used to calculate the load balancing degree according to the sorted link priority scores and the sorted task priority scores to obtain each load balancing degree; A calculation and determination module, used to calculate each scheduling decision variable according to each load balancing degree, and determine the maximum value of the scheduling decision variable from each scheduling decision variable; A first determination module, used to determine the task and call link corresponding to the maximum value of the scheduling decision variable; The scheduling module is used to schedule the tasks and call links corresponding to the maximum value of the scheduling decision variable to the nodes corresponding to the tasks corresponding to the maximum value of the scheduling decision variable, and return to the step of calculating the link priority of each call link by a preset link priority calculation formula during the execution of the scheduling task, obtaining the priority score of each link and sorting it until the stress testing task distribution is completed.
Citation Information
Patent Citations
Pressure testing method, device, equipment and medium
CN116560918A
Pressure testing method and device and storage medium
CN118473972A
Distributed pressure testing system and method
US20140298101A1
Method and apparatus for testing stress based on cloud service
US20210390029A1