Load regulation method, apparatus and device
By dynamically updating the load distribution strategy using the particle swarm optimization algorithm, the problem of low resource utilization caused by servers with different construction standards is solved, achieving high efficiency and accuracy in load control, and ensuring the stable operation of the system and the efficiency of business processing in dynamic environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- CHINA MOBILE GROUP ZHEJIANG
- Filing Date
- 2026-02-05
- Publication Date
- 2026-06-19
AI Technical Summary
In existing technologies, because the resource pool contains servers from different construction periods and with different construction standards, the server computing speed and user experience vary greatly. When allocating network service data processing requests through a round-robin algorithm, resource utilization is low and service data processing efficiency is poor.
A load distribution strategy is constructed using the particle swarm optimization algorithm. The velocity and position of the particle swarm are iteratively updated through dynamic learning factors. Combined with the load status and business type of the target server, the fitness value of the particles is determined to optimize the load distribution strategy.
It enables the rapid and accurate determination of load allocation strategies under dynamic changes in server load and fluctuations in network traffic, improving the efficiency and accuracy of load control, ensuring stable and efficient system operation, and enhancing the processing effect of network business data.
Smart Images

Figure CN122247987A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of computer technology, and in particular to a load control method, apparatus, and device. Background Technology
[0002] With the rapid development of cloud computing technology, servers are facing unprecedented challenges. In order to cope with high concurrency access and ensure high availability and high performance of services, load balancing technology has emerged and gradually become a core component of server architecture.
[0003] For example, a round-robin algorithm can be used to distribute network service data processing requests to various servers in a resource pool in a fixed order. However, as the resource pool expands, it contains servers built at different times and to different standards. This results in significant differences in computing speed and user experience among different servers within the same resource pool. Consequently, allocating network service data processing requests in a fixed order using a round-robin algorithm leads to low server utilization and poor service data processing efficiency. Therefore, a technical solution is needed to improve the efficiency and accuracy of load regulation to enhance the effectiveness of network service data processing. Summary of the Invention
[0004] The purpose of this invention is to provide a technical solution that can improve the efficiency and accuracy of load regulation, thereby enhancing the effectiveness of network service data processing.
[0005] To solve the above-mentioned technical problems, the embodiments of the present invention are implemented as follows: In a first aspect, an embodiment of the present invention provides a load regulation method, the method comprising: Receive load balancing requests for network service data; In response to the load regulation request, a target server corresponding to the network service data is determined, and a particle swarm corresponding to the target server is constructed, wherein the particles in the particle swarm are used to characterize the load distribution strategy. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated, and the fitness value of the particle during the iteration process is determined according to the updated position information, the load status of the target server, and the service type of the network service data. Based on the fitness value of the particle, the global optimal position of the particle swarm during the iteration process is determined, and when the iteration update ends, the target load allocation strategy is determined and executed based on the global optimal position of the particle swarm.
[0006] Secondly, embodiments of the present invention provide a load regulation device, the device comprising: The request receiving module is used to receive load regulation requests for network service data. A particle construction module is used to respond to the load control request, determine the target server corresponding to the network service data, and construct a particle swarm corresponding to the target server. The particles in the particle swarm are used to characterize the load distribution strategy. The iterative update module is used to iteratively update the velocity and position of the particle swarm based on a dynamic learning factor, and determine the fitness value of the particle during the iteration process according to the updated position information, the load status of the target server, and the service type of the network service data. The strategy execution module is used to determine the global optimal position of the particle swarm during the iteration process based on the fitness value of the particle, and to determine and execute the target load allocation strategy based on the global optimal position of the particle swarm after the iteration update ends.
[0007] Thirdly, embodiments of the present invention provide a load control device, including a processor, a memory, and a computer program stored in the memory and executable on the processor. When the computer program is executed by the processor, it implements the steps of the load control method provided in the above embodiments.
[0008] Fourthly, embodiments of the present invention provide a computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the steps of the load control method provided in the above embodiments.
[0009] Fifthly, embodiments of the present invention provide a computer program product, including a computer program that, when executed by a processor, implements the steps of the load control method provided in the above embodiments. Attached Figure Description
[0010] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0011] Figure 1 This is a schematic flowchart of a load control method according to the present invention; Figure 2 This is a schematic flowchart illustrating the process of updating the position and velocity of a particle according to the present invention. Figure 3 This is a schematic diagram illustrating the process of determining a fitness value according to the present invention; Figure 4 This is a schematic diagram of a load regulation process according to the present invention; Figure 5 This is a flowchart illustrating the process of determining the globally optimal position according to the present invention. Figure 6 This is a flowchart illustrating the triggering process of a load regulation request according to the present invention. Figure 7 This is a schematic diagram of the structure of a load regulation device according to the present invention; Figure 8 This is a schematic diagram of the structure of a load regulation device according to the present invention. Detailed Implementation
[0012] This invention provides a load regulation method, apparatus, and device.
[0013] To enable those skilled in the art to better understand the technical solutions of this invention, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this invention.
[0014] like Figure 1 As shown, this embodiment of the invention provides a load regulation method. The execution subject of this method can be a server, which can be a standalone server or a server cluster composed of multiple servers. Specifically, the method may include the following steps: In step S102, a load regulation request for network service data is received.
[0015] Among them, network service data can be data corresponding to any network service to be processed. For example, network services can be video call services, voice call services, message transmission services, video browsing services, etc.
[0016] In implementation, the server can trigger load balancing requests for network service data based on a preset load balancing cycle. For example, assuming that based on historical network service data, it can be determined that the amount of network service data within a preset time period (such as 10:00-11:00) exceeds a preset threshold, the server can trigger a load balancing request for network service data when that preset time period arrives. Alternatively, the server can also receive load balancing requests for network service data triggered by users. In addition, there can be various other methods for triggering load balancing requests. The triggering methods can vary depending on the actual application scenario, and this specification does not specifically limit them in this way.
[0017] In step S104, in response to the load regulation request, the target server corresponding to the network service data is determined, and the particle swarm corresponding to the target server is constructed.
[0018] Among them, the particles in the particle swarm can be used to characterize the load distribution strategy.
[0019] In implementation, the server can determine the resource pool for processing network service data based on the service type of the network service data, and identify the servers in the resource pool as target servers in order to construct a particle swarm corresponding to the target server.
[0020] The server can initialize the particle swarm, determine the number of particles in the swarm, initialize particle positions and velocities, and set algorithm parameters. Specifically: The server can obtain the server cluster (such as a resource pool) corresponding to the target server for the network service data, and set the number of particles N in the particle swarm based on the size of the server cluster, the performance differences between the target servers, and the complexity of the actual business requirements. The number of particles N can be linearly positively correlated with the size m of the server cluster (i.e., the number of target servers). For example, when the size of the server cluster is small (e.g., m≤100), the number of particles N can be a large multiple of N∈[8m, 10m] to ensure that the particle swarm has enough search space to cover all load distribution combinations. When the size of the server cluster is large (e.g., m>100), the number of particles N can be a small multiple of N∈[1m, 7m] to avoid excessive particle count leading to a surge in computational complexity.
[0021] Each particle can represent a load balancing strategy, aiming to find the optimal allocation method through particle search. The set of target servers participating in load balancing. ={ , , These target servers can be the target objects for load balancing.
[0022] The server can randomly assign an initial position and velocity to each particle. The position of each particle in the particle swarm can be determined. =( , , )express, Represents particles Assigned to target server The request ratio must meet the following requirements. =1 and 0≤ ≤1, ensuring reasonable and effective load distribution. Particle velocity can be represented by a vector. =( , , This indicates that the initial velocity is randomly selected within a reasonable range, and the initial velocity range can be set to [-]. , Randomly select a value from within. = The larger the server cluster size m, the larger the dimension of the solution space, and the smaller the speed step size of a single dimension should be to avoid excessive position update amplitude.
[0023] In step S106, the velocity and position of the particle swarm are iteratively updated based on the dynamic learning factor, and the fitness value of the particles during the iteration process is determined according to the updated position information, the load status of the target server, and the service type of the network service data.
[0024] The load status of the target server can include CPU utilization, memory utilization, and bandwidth utilization. CPU utilization can be used to reflect the processor's busyness. Too high a CPU utilization will slow down the server's request processing speed. Memory utilization can reflect the consumption of memory resources. Insufficient memory utilization will affect data storage and processing capabilities. Network bandwidth utilization can be used to indicate the utilization of network communication capabilities. Too high a bandwidth utilization may lead to network congestion and affect data transmission speed. By obtaining these load status indicators in real time, the current load status of the target server can be accurately monitored.
[0025] In implementation, the server can use professional server monitoring tools to continuously monitor the load status indicators of each target server in real time. The load status of the j-th target server can include CPU utilization. Memory usage Bandwidth utilization Additionally, servers can deploy traffic monitoring devices at the network ingress or use software monitoring tools, such as NetFlow Analyzer and Wireshark, which by default collect network traffic data corresponding to network service data every 30 seconds.
[0026] Specifically, when the traffic fluctuation amplitude is less than a preset threshold (e.g., 10%) for multiple consecutive sampling periods, the sampling frequency can be automatically switched to a low-frequency period (e.g., once per minute). When a preset number of traffic fluctuations occur consecutively within a preset number of sampling periods (e.g., 3), the sampling frequency can be increased to a preset frequency such as 50%. The collected network service data can include the request count (RequestNum), which reflects the total number of requests initiated by clients in the current network; a sudden increase in this number may lead to increased server load. It can also include the request type (RequestType), i.e., the service type. Different types of requests have different server resource requirements; for example, video streaming requests for video viewing services require a large amount of network bandwidth and computing resources, while text requests for text processing services have relatively lower requirements. Obtaining this network service data can help to rationally allocate the load based on traffic characteristics and improve resource utilization efficiency.
[0027] The server can iteratively update the velocity and position of the particle swarm based on pre-set inertia weights, dynamic learning factors, etc. During the iterative update process, the server determines the fitness value of the particles in the current iteration based on the updated position information corresponding to the previous iteration, the load status of the target server, and the service type of the network service data.
[0028] The server can use pre-trained fitness values to determine the model. Based on the updated position information corresponding to the previous iteration, the load status of the target server, and the service type of the network service data, the fitness value of the particle in the current iteration can be determined. The fitness value determination model can be a model built based on a preset deep learning algorithm.
[0029] In step S108, the global optimal position of the particle swarm during the iteration process is determined based on the fitness value of the particle, and the target load allocation strategy is determined and executed based on the global optimal position of the particle swarm after the iteration update ends.
[0030] In implementation, the server can filter out the global optimal fitness value in the particle swarm based on the fitness value of each particle in each iteration, and determine the global optimal position of the particle swarm based on the global optimal fitness value after the iteration update ends. Based on the global optimal position, the server can determine the target load allocation strategy and execute the target load allocation strategy.
[0031] There are several methods to determine whether the iterative update has ended. For example, one can determine whether the number of iterations has reached the maximum number of iterations T. When the number of iterations reaches the maximum number of iterations T, it is considered that the algorithm has made sufficient search attempts and the iterative update can be stopped. Alternatively, one can determine whether the change in the global optimal fitness value over several consecutive iterations is less than a preset threshold. If it is less than the preset threshold If the result is close to the optimal solution, it indicates that further iterative optimization will not yield significant results, and iterative updates can be stopped.
[0032] This invention provides a load balancing method that receives a load balancing request for network service data. In response to the request, it determines the target server corresponding to the network service data and constructs a particle swarm corresponding to the target server. The particles in the particle swarm represent load allocation strategies. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated. Based on the updated position information, the load status of the target server, and the service type of the network service data, the fitness value of each particle during the iteration process is determined. Based on the fitness value of each particle, the globally optimal position of the particle swarm during the iteration process is determined. Upon completion of the iteration update, the target load allocation strategy is determined and executed based on the globally optimal position of the particle swarm. This allows for real-time collection of the target server's load status and the traffic information corresponding to the network service data. Based on the collected real-time data, the particle swarm algorithm is used to quickly and accurately determine the target load allocation strategy. This allows the target load allocation strategy to quickly adapt to dynamic changes in server load and network traffic fluctuations, ensuring stable and efficient system operation under various conditions. This guarantees the efficiency and accuracy of load balancing and improves the processing effect of network service data.
[0033] In practical applications, the specific processing method for iteratively updating the velocity and position of the particle swarm based on the dynamic learning factor in step S106 above can vary. One optional processing method is provided below, such as... Figure 2 As shown, the specific process may include the following steps S1062 to S1066.
[0034] In step S1062, the inertia weight, the first learning factor, and the second learning factor corresponding to the current iteration number are determined according to the iteration stage to which the current iteration number belongs.
[0035] The iteration phase includes a first phase and a second phase. The inertia weight corresponding to the first phase can be greater than the inertia weight corresponding to the second phase. The first learning factor can be greater than the second learning factor in the first phase, and the first learning factor can be less than the second learning factor in the second phase.
[0036] In practice, the server can determine the iteration stage to which the current iteration belongs based on the current iteration number and a preset threshold number. For example, if the current iteration number is not greater than the preset threshold number, it can be determined that the current iteration belongs to the first stage; if the current iteration number is greater than the preset threshold number, it can be determined that the current iteration belongs to the second stage.
[0037] Inertia weight To balance the global and local search capabilities of particles, for example, in the early stage of iterative updates, the inertial weight can be larger to facilitate global search, while in the later stage of iterative updates, the inertial weight can be smaller to focus on local search. That is, the inertial weight corresponding to the first stage can be greater than the inertial weight corresponding to the second stage.
[0038] The preset number of times threshold and the determination method of each parameter (i.e., inertia weight, first learning factor and second learning factor) can be determined based on experiments and data analysis. The determination method may be different for different server cluster sizes and network service data. This specification does not specifically limit this in the embodiments.
[0039] In step S1064, the velocity of the particle swarm is updated based on the inertia weight, the first learning factor, and the second learning factor corresponding to the current iteration number, to obtain the velocity corresponding to the current iteration number.
[0040] The first learning factor characterizes the degree of learning from the particle's own historical best position, while the second learning factor characterizes the degree of learning from the global best position of the particle swarm. Second learning factor The degree to which a particle learns from its own historical best and global best positions can be controlled separately.
[0041] In implementation, the server can use the following formula to determine the speed at which the i-th particle is assigned to the j-th target server in the (t+1)-th iteration update. By introducing adaptive adjustment parameters and dynamic learning factors, the algorithm's search efficiency and optimization ability can be improved. The update formula is: (t+1)= · (t)+ · ·( )+ · ·( )+ ·(rand()-0.5) in, The inertia weight in the t-th iteration update changes dynamically with the number of iterations. In the early stages of the algorithm, a larger value can be set. This value endows particles with strong global search capabilities, enabling them to quickly explore different regions within a vast space, seeking potential optimal solutions and avoiding premature entrapment in local optima. As iteration progresses, The particle can be gradually reduced, its local exploration capability is enhanced, and it begins to focus on the region near the current better solution to conduct a fine search and improve the accuracy of optimization.
[0042] and These are the first learning factor and the second learning factor, respectively. The adjustment rule for the learning factor can be dynamically adjusted based on the iteration process, convergence state, and search space characteristics.
[0043] For example, = ( - , = ( - , Where T is the maximum number of iterations, which can be determined based on the size of the server cluster corresponding to the target server. For example, for small clusters with a smaller solution space, T can be 200, while for large clusters with a larger solution space requiring more iterations, T can be 500.
[0044] In the early stages of iteration (such as the first phase). =2.5, 0.5 =2.5, 0.5 That is, in the first stage. =2.5、 In this way, particles are more inclined to explore independently, covering a wider solution space.
[0045] In the later stages of iteration (such as the second phase) =0.5、 Particles tend to perform fine-grained local searches, improving the accuracy of load allocation schemes.
[0046] · ·( It can be used to represent the particle's own historical best position. The learning part, · ·( ) is moving towards the globally optimal position. The learning part.
[0047] and It is a random number between [1,0], which can introduce randomness into the particle search process, help the particle escape the local optimum trap, explore more solution space, and increase the diversity of exploration.
[0048] ·(rand()-0.5) represents the random perturbation term. It is a parameter that controls the strength of random disturbance terms. The more target servers (m) there are and the more complex the business types (n), the higher the dimension of the solution space, and the greater the need to increase it. To enhance the ability to explore random perturbations, small clusters (m≤100) are used. Large clusters (m≥100) Adding extra random perturbations to particle velocity helps particles escape the attraction of local optima when they get trapped, making the exploration more comprehensive and in-depth.
[0049] In step S1066, the position of the particle swarm is updated based on the velocity corresponding to the current iteration number and the position of the particle swarm corresponding to the previous iteration number.
[0050] In practice, the server can update the particle's position based on the updated velocity using the following formula: = + (t), where, This represents the proportion of requests from target server j allocated to particle i at time t. (t+1) is the updated velocity; adding the two together gives the proportion of requests allocated by particle i to target server j at the next moment. .
[0051] After updating the particle positions, boundary processing is required to ensure... (t+1)=1 and 0≤ (t+1)≤1. This is because (t+1) represents the request allocation ratio, which needs to be within a reasonable range, and the sum of the request allocation ratios of all target servers should be 1 to ensure the rationality and effectiveness of the load balancing scheme. If calculated... (t+1)≠1. Without adjusting the boundary values, negative or excessive load distribution may occur, rendering the load allocation scheme ineffective. Therefore, a global load normalization method is used to redistribute the load, i.e., the sum of the current loads S = (t+1), if S>1: (t+1) = (t+1) / S, if S<1, the remaining proportion (1-S) is allocated to each target server according to the current proportion. (t+1) = (t+1)+ .
[0052] In practical applications, the specific processing method for determining the fitness value of each particle in the particle swarm during the iteration process in step S106 above, based on the updated location information, the load status of the target server, and the service type of the network service data, can vary. The following provides one optional processing method, such as... Figure 3 As shown, the specific process may include the following steps S1068 to S10616.
[0053] In step S1068, the position information of each particle is determined based on the updated position information.
[0054] Location information can be used to characterize the proportion of requests that particles are allocated to the server.
[0055] In step S10610, the server load assessment value is determined based on the position information of each particle and the load status of the target server.
[0056] In step S10612, the type proportion of network service data corresponding to each service type and the average allocation ratio of each service type are obtained under the load allocation strategy corresponding to the global optimal position at the current iteration number.
[0057] In step S10614, the business type allocation ratio is determined based on the type proportion and the average allocation proportion.
[0058] In step S10616, based on the server load assessment value and the business type allocation ratio, the fitness value corresponding to each particle in the particle swarm in the current iteration number is determined.
[0059] In implementation, the server can construct a fitness function f based on the target server's load status and the network traffic data corresponding to the network service data. This is to enable the target server to achieve load balancing and meet diverse business needs.
[0060] f
[0061] in, It can be used to represent the load on the target server (i.e., the server load assessment value). Particle i is assigned to the target server. The proportion of requests, These are the target servers The CPU utilization, memory utilization, and network bandwidth utilization of each target server are measured. The load status metrics of each target server are multiplied by their corresponding request allocation ratio, summed, and then squared. This amplifies the impact of load imbalance. The smaller this value is when the loads of all target servers are closer, the more balanced the load distribution, and the larger the fitness function value, indicating that the load allocation strategy represented by the particles performs better in load balancing.
[0062] This can be used to measure the actual distribution ratio of request types (i.e., the distribution ratio of business types). n represents the total number of business types. This represents the first load distribution under the current load distribution strategy. The actual proportion of each business type among all types (i.e., type percentage). Then it is the first The average allocation percentage of each business type is calculated. The absolute value is used to ensure that the entire data is positive. By summing up all n business types, we can obtain the overall allocation difference value of request types. The smaller the difference value, the closer the allocation ratio of various requests in the load balancing scheme is to the ideal allocation ratio.
[0063] As a weighting coefficient, multiplied by Previously, it could be used to flexibly adjust the importance of business type matching in the entire fitness function. The greater the difference in resource consumption between business types, the higher the weighting coefficient. The value can be higher to ensure business matching. Calculate the standard deviation of resource consumption for each business type; the standard deviation should be <30%. ∈[0.1, 0.5]; standard deviation ≥30%, ∈ (0.5, 1.0).
[0064] like Figure 4 As shown, the position of each particle is substituted into the fitness function f. The corresponding fitness values are calculated. A higher fitness value indicates that the load distribution strategy represented by the particle is more effective in balancing server load and meeting the requirements of different business types, thus representing a more optimal strategy. Calculating the fitness values of all particles provides a basis for subsequent particle updates and optimal solution searches.
[0065] In practical applications, the specific processing method for determining the global optimal position of the particle swarm during the iteration process based on the fitness value of the particle in step S108 above can vary. The following provides one optional processing method, such as... Figure 5 As shown, the specific process may include the following steps S1082 to S1084.
[0066] In step S1082, the optimal fitness value of each particle in the current iteration is determined based on the fitness value of each particle in the current iteration and the optimal fitness value of each particle in the historical iterations.
[0067] In step S1084, the global optimal fitness value of the particle swarm in the current iteration is determined based on the optimal fitness value of each particle in the current iteration, and the position information of the particle corresponding to the global optimal fitness value is determined as the global optimal position of the particle swarm in the current iteration.
[0068] In implementation, the server can update the individual optimal and global optimal positions based on the optimal fitness value of each particle in the current iteration, and compare the current fitness values f of each particle. and its own historical best fitness value f If f f This indicates that the load distribution strategy represented by the current particle is optimal, and the optimal position of the individual is updated. = Compare the current fitness values of all particles and find the maximum value f. and their corresponding particle positions If f Greater than the current global optimal fitness value f Then update the global optimal position. = The global optimal position can represent the optimal load allocation strategy found by the particle in the current iteration. As the iteration continues to optimize, it gradually approaches the true optimal solution.
[0069] In practical applications, the specific processing method for receiving load regulation requests for network service data in step S102 above can vary. The following provides one optional processing method, such as... Figure 6 As shown, the specific process may include the following steps S1022 to S1024.
[0070] In step S1022, the load status of the target server and network service data are obtained.
[0071] In step S1024, based on the load status of the target server and / or network service data, it is determined whether the load control requirements are met, and if the load control requirements are met, a load control request for the network service data is triggered.
[0072] In implementation, intelligent load balancing control is employed. After the algorithm converges, the globally optimal position is obtained, and the corresponding server request allocation ratio is the optimal load balancing strategy calculated by the optimized particle swarm optimization algorithm. During the implementation of the target load allocation strategy, the server can continuously monitor the load status and network traffic changes of the target server in real time. If, based on the load status and / or network service data of the target server, it is determined that the load control requirements are met, a load control request for network service data can be triggered again.
[0073] In practical applications, the specific processing method for determining whether the load control requirements are met based on the load status and / or network service data of the target server in step S1024 above can be varied. The following provides an optional processing method, which may specifically include the processing of step A1 or step A2.
[0074] In step A1, if there are servers in the target server whose CPU utilization is higher or lower than the preset utilization threshold, then the load control requirements are met.
[0075] In step A2, if the increase in network service data exceeds a preset increase threshold, and / or the distribution of service types in the network service data changes, then the load control requirement is determined to be met.
[0076] In implementation, such as Figure 4 As shown, if an imbalance in the load on the target server is detected (e.g., the CPU utilization of a target server remains consistently too high or too low) or a significant change occurs in network traffic (e.g., a sudden surge in the number of requests or a change in the distribution of request types), the feedback mechanism can be activated immediately. Newly collected data can be re-input into the aforementioned optimized particle swarm optimization algorithm process for a new round of load balancing optimization calculations, allowing for timely adjustments to the server load distribution strategy and ensuring the system remains in optimal operating condition.
[0077] By collecting server status and traffic data in real time, when load imbalance or traffic surges are detected, the optimized particle swarm algorithm is triggered to recalculate the optimal allocation scheme, realizing closed-loop control of "detection-calculation-adjustment" and solving the problem of insufficient dynamic perception in existing technologies.
[0078] Through continuous monitoring and optimization, the particle swarm optimization algorithm is regularly evaluated and improved. Algorithm parameters (such as dynamic learning factors and inertia weights) are adjusted promptly based on actual server cluster operating data and business development trends. Simultaneously, the algorithm's performance in different scenarios is monitored, leading to improvements and refinements to adapt to changing server loads and network environments. This continuously enhances server load balancing and overall system performance, providing users with stable and efficient services. Furthermore, by adaptively setting the particle number n based on the server size m and controlling the intensity of random perturbation terms, and dynamically adjusting algorithm parameters through normalization of the iteration count t and the maximum iteration count T, the optimization efficiency of the algorithm under various business scenarios can be ensured.
[0079] The optimized particle swarm optimization algorithm is a deep improvement upon the traditional algorithm. Addressing the dynamic and complex nature of server load balancing scenarios, the formulas for updating particle velocity and position are optimized. Adaptive inertial weights are introduced, with larger weights during the initial global search for rapid solution space exploration, and smaller weights during later local searches for more precise approximation of the optimal solution. Simultaneously, the learning factor is adjusted to dynamically change according to the particle search process, enhancing the algorithm's ability to escape local optima and improving optimization efficiency and accuracy. Specifically, this is achieved by introducing adaptive inertial weights. With dynamic learning factors This algorithm achieves key improvements over the traditional PSO algorithm. In the early stages, it rapidly explores the server load distribution solution space by setting a large inertia weight. In the later stages, it focuses on local optima by decaying the inertia weight. Simultaneously, the first learning factor... The second learning factor can decay from 2.5 to 0.5. The value can be increased from 0.5 to 2.5, enhancing the particle's ability to escape local optima and effectively solving the problem that existing static algorithms cannot adapt to dynamic changes in server load.
[0080] By employing specific strategies and technologies, massive client requests are rationally distributed across target servers within a server cluster. This aims to fully utilize the computing, storage, and network resources of each target server within the cluster, preventing some target servers from experiencing performance degradation due to overload while others remain idle, thereby improving the overall performance, reliability, and response speed of the server cluster system.
[0081] By utilizing various sensors and monitoring tools, server load status (such as CPU utilization, memory usage, and network bandwidth consumption) and network traffic information (number of requests, request type, traffic peaks and troughs) can be collected in real time. Based on this real-time data, optimization algorithms and preset intelligent rules can be used to automatically and dynamically adjust server load balancing strategies, enabling intelligent and precise allocation and management of server resources to adapt to constantly changing business needs and network environments, ensuring stable and efficient system operation under various conditions.
[0082] The optimized particle swarm optimization algorithm can accurately calculate the optimal server load distribution strategy. Compared with traditional simple distribution algorithms, it can more effectively balance server load, reduce load imbalance, and improve overall system performance and stability. The intelligent control mechanism can fully utilize server resources, avoid resource idleness or overload, improve resource utilization, reduce operating costs, and enhance system scalability and business carrying capacity. The fitness function considers business factors such as request type, enabling reasonable load distribution based on different business needs. It provides differentiated services for businesses with high real-time requirements and high data accuracy requirements, improving user experience and business processing efficiency, and providing better business support capabilities. Through continuous monitoring and regular optimization of algorithms and parameters, it can continuously adapt to changing environments and business needs. Even as the server cluster scales up, business volume increases, or the network environment changes, it maintains good performance, possesses long-term stability and reliability, and has self-optimization and continuous improvement capabilities.
[0083] In markets such as cloud computing and data centers, efficient server load balancing technology is a key competitive advantage. The load control method provided in this description can improve server cluster performance and resource utilization, helping enterprises provide more stable and efficient services, attract more customers, and enhance their competitiveness in the market. Furthermore, it can optimize server load balancing, reducing server resource waste, lowering energy consumption and hardware procurement costs, as well as operating costs, saving enterprises significant operating funds and improving economic efficiency. Moreover, this technology is not only applicable to traditional data centers and cloud computing platforms but can also be extended to emerging fields such as the Internet of Things and edge computing, meeting their needs for efficient management of equipment resources and opening up new business growth points for enterprises.
[0084] In practical applications, such as video surveillance quality diagnostic platforms that need to simultaneously handle the uploading, transcoding, and image quality detection of thousands of high-definition video streams, traditional load balancing algorithms cannot detect the dynamic load of each server's CPU / memory / bandwidth in real time, affecting the platform's real-time performance and accuracy in detection and diagnosis. By optimizing the dynamic optimization capabilities of the particle swarm optimization algorithm, the platform's stability and accuracy can be ensured, resolving the load imbalance problem under high concurrency of video streams.
[0085] In addition, since server clusters may include a mix of old servers and new GPU servers, traditional algorithms allocate tasks according to uniform rules, which may result in high-performance servers handling light text tasks and low-performance servers carrying heavy video streaming services, causing a mismatch between resource utilization and server performance. However, by optimizing the dynamic optimization capability of the particle swarm optimization algorithm and the multi-index fitness function, resource utilization can be improved and the problem of resource waste in heterogeneous server clusters can be solved.
[0086] Since video surveillance quality diagnostic platforms involve multiple types of services such as video streams, recording detection, and intelligent analysis, traditional methods cannot dynamically allocate bandwidth strategies based on service attributes. By optimizing the dynamic optimization capability of the particle swarm optimization algorithm and balancing the load with weight coefficients to match service requirements, the real-time service response latency can be reduced, and the problem of intelligent scheduling for diverse services can be solved.
[0087] This specification provides a load balancing method that receives a load balancing request for network service data. In response to the request, it determines the target server corresponding to the network service data and constructs a particle swarm corresponding to the target server. The particles in the particle swarm represent load allocation strategies. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated. Based on the updated position information, the load status of the target server, and the service type of the network service data, the fitness value of each particle during the iteration process is determined. Based on the fitness value of each particle, the globally optimal position of the particle swarm during the iteration process is determined. Upon completion of the iteration update, the target load allocation strategy is determined and executed based on the globally optimal position of the particle swarm. This allows for real-time collection of the target server's load status and the traffic information corresponding to the network service data. Based on the collected real-time data, the particle swarm algorithm is used to quickly and accurately determine the target load allocation strategy. This allows the target load allocation strategy to quickly adapt to dynamic changes in server load and network traffic fluctuations, ensuring stable and efficient system operation under various conditions. This guarantees the efficiency and accuracy of load balancing and improves the processing effect of network service data.
[0088] The above describes the load regulation method provided in the embodiments of this specification. Based on the same idea, the embodiments of this specification also provide a load regulation device, such as... Figure 7 As shown.
[0089] The load control device includes: a request receiving module 701, a particle construction module 702, an iterative update module 703, and a strategy execution module 704, wherein: The request receiving module 701 is used to receive load regulation requests for network service data. The particle construction module 702 is used to respond to the load control request, determine the target server corresponding to the network service data, and construct a particle swarm corresponding to the target server, wherein the particles in the particle swarm are used to characterize the load distribution strategy. The iterative update module 703 is used to iteratively update the velocity and position of the particle swarm based on a dynamic learning factor, and determine the fitness value of the particle during the iteration process according to the updated position information, the load status of the target server, and the service type of the network service data. The strategy execution module 704 is used to determine the global optimal position of the particle swarm during the iteration process based on the fitness value of the particle, and to determine and execute the target load allocation strategy based on the global optimal position of the particle swarm when the iteration update ends.
[0090] In the embodiments of this specification, the iterative update module 703 is used for: Based on the iteration stage to which the current iteration number belongs, determine the inertia weight, the first learning factor, and the second learning factor corresponding to the current iteration number. The iteration stage includes a first stage and a second stage. The inertia weight corresponding to the first stage is greater than the inertia weight corresponding to the second stage. The first learning factor is greater than the second learning factor in the first stage and less than the second learning factor in the second stage. Based on the inertia weight, the first learning factor, and the second learning factor corresponding to the current iteration number, the velocity of the particle swarm is updated to obtain the velocity corresponding to the current iteration number. The first learning factor is used to characterize the degree of learning from the particle's own historical best position, and the second learning factor is used to characterize the degree of learning from the global best position of the particle swarm. The position of the particle swarm is updated based on the velocity corresponding to the current iteration number and the position of the particle swarm corresponding to the previous iteration number.
[0091] In the embodiments of this specification, the iterative update module 703 is used for: Based on the updated position information, the position information of each particle is determined, and the position information is used to characterize the proportion of requests that the particle is allocated to the server; Based on the position information of each particle and the load status of the target server, a server load assessment value is determined; Under the load distribution strategy corresponding to the globally optimal position at the current iteration number, obtain the type proportion of network service data for each service type, and the average distribution ratio for each service type; Based on the aforementioned type proportions and average distribution proportions, the business type allocation ratio is determined; Based on the server load assessment value and the business type allocation ratio, the fitness value corresponding to each particle in the particle swarm is determined in the current iteration number.
[0092] In this embodiment of the specification, the policy execution module 704 is used for: Based on the fitness value of each particle in the current iteration and the optimal fitness value of each particle in the historical iterations, determine the optimal fitness value of each particle in the current iteration. Based on the optimal fitness value of each particle in the current iteration, the global optimal fitness value of the particle swarm in the current iteration is determined, and the position information of the particle corresponding to the global optimal fitness value is determined as the global optimal position of the particle swarm in the current iteration.
[0093] In this embodiment of the specification, the request receiving module 701 is used for: Obtain the load status of the target server and the network service data; Based on the load status of the target server and / or the network service data, determine whether the load regulation requirements are met, and if the load regulation requirements are met, trigger a load regulation request for the network service data.
[0094] In this embodiment of the specification, the request receiving module 701 is used for: If any of the target servers has a CPU utilization rate higher or lower than a preset utilization threshold, then the load control requirement is determined to be met; or, If the increase in the network service data exceeds a preset increase threshold, and / or the distribution of the service types of the network service data changes, then the load regulation requirement is determined to be met.
[0095] This specification provides a load balancing device that receives load balancing requests for network service data. In response to these requests, it determines the target server corresponding to the network service data and constructs a particle swarm corresponding to the target server. The particles in the particle swarm represent load allocation strategies. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated. Based on the updated position information, the load status of the target server, and the service type of the network service data, the fitness value of each particle during the iteration process is determined. Based on the fitness value of each particle, the globally optimal position of the particle swarm during the iteration process is determined. Upon completion of the iteration update, the target load allocation strategy is determined and executed based on the globally optimal position of the particle swarm. This allows for real-time collection of the target server's load status and the traffic information corresponding to the network service data. Based on the collected real-time data, the particle swarm algorithm is used to quickly and accurately determine the target load allocation strategy. This allows the target load allocation strategy to quickly adapt to dynamic changes in server load and network traffic fluctuations, ensuring stable and efficient system operation under various conditions. This guarantees the efficiency and accuracy of load balancing and improves the processing effect of network service data.
[0096] The above are the load regulation devices provided in the embodiments of this specification. Based on the same idea, the embodiments of this specification also provide a load regulation device, such as... Figure 8 As shown.
[0097] The load control device can provide terminal equipment or servers, etc., for the above embodiments.
[0098] Load control devices can vary considerably depending on their configuration and performance. They may include one or more processors 801 and memory 802, with memory 802 storing one or more application programs or data. Memory 802 may be temporary or persistent storage. The application programs stored in memory 802 may include one or more modules (not shown), each module including a series of computer-executable instructions for the load control device. Furthermore, processor 801 may be configured to communicate with memory 802 and execute the series of computer-executable instructions in memory 802 on the load control device. The load control device may also include one or more power supplies 803, one or more wired or wireless network interfaces 804, one or more input / output interfaces 805, and one or more keyboards 806.
[0099] Specifically, in this embodiment, the load control device includes a memory and one or more programs, wherein one or more programs are stored in the memory, and one or more programs may include one or more modules, and each module may include a series of computer-executable instructions for the load control device, and is configured to be executed by one or more processors. The one or more programs include computer-executable instructions for performing the following: Receive load balancing requests for network service data; In response to the load regulation request, a target server corresponding to the network service data is determined, and a particle swarm corresponding to the target server is constructed, wherein the particles in the particle swarm are used to characterize the load distribution strategy. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated, and the fitness value of the particle during the iteration process is determined according to the updated position information, the load status of the target server, and the service type of the network service data. Based on the fitness value of the particle, the global optimal position of the particle swarm during the iteration process is determined, and when the iteration update ends, the target load allocation strategy is determined and executed based on the global optimal position of the particle swarm.
[0100] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the load regulation device embodiments are basically similar to the method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions of the method embodiments.
[0101] This specification provides a load balancing device that receives load balancing requests for network service data. In response to these requests, it determines the target server corresponding to the network service data and constructs a particle swarm corresponding to the target server. The particles in the particle swarm represent load allocation strategies. Based on a dynamic learning factor, the speed and position of the particle swarm are iteratively updated. Based on the updated position information, the load status of the target server, and the service type of the network service data, the fitness value of each particle during the iteration process is determined. Based on the fitness value of each particle, the globally optimal position of the particle swarm during the iteration process is determined. Upon completion of the iteration update, the target load allocation strategy is determined and executed based on the globally optimal position of the particle swarm. This allows for real-time collection of the target server's load status and the traffic information corresponding to the network service data. Based on the collected real-time data, the particle swarm algorithm is used to quickly and accurately determine the target load allocation strategy. This allows the target load allocation strategy to quickly adapt to dynamic changes in server load and network traffic fluctuations, ensuring stable and efficient system operation under various conditions. This guarantees the efficiency and accuracy of load balancing and improves the processing effect of network service data.
[0102] Furthermore, based on the above Figures 1 to 6 The method shown in this specification, along with one or more embodiments, also provides a storage medium for storing computer-executable instruction information. In one specific embodiment, the storage medium can be a USB flash drive, optical disc, hard disk, etc. When the computer-executable instruction information stored in the storage medium is executed by a processor, it can achieve the following process: Receive load balancing requests for network service data; In response to the load regulation request, a target server corresponding to the network service data is determined, and a particle swarm corresponding to the target server is constructed, wherein the particles in the particle swarm are used to characterize the load distribution strategy. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated, and the fitness value of the particle during the iteration process is determined according to the updated position information, the load status of the target server, and the service type of the network service data. Based on the fitness value of the particle, the global optimal position of the particle swarm during the iteration process is determined, and when the iteration update ends, the target load allocation strategy is determined and executed based on the global optimal position of the particle swarm.
[0103] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the above-described storage medium embodiment is basically similar to the method embodiment, so the description is relatively simple; relevant parts can be referred to the description of the method embodiment.
[0104] This specification provides a storage medium that receives load balancing requests for network service data. In response to these requests, it determines the target server corresponding to the network service data and constructs a particle swarm corresponding to the target server. The particles in the particle swarm represent load allocation strategies. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated. Based on the updated position information, the load status of the target server, and the service type of the network service data, the fitness value of each particle during the iteration process is determined. Based on the fitness value of each particle, the globally optimal position of the particle swarm during the iteration process is determined. Upon completion of the iteration update, the target load allocation strategy is determined and executed based on the globally optimal position of the particle swarm. This allows for real-time collection of the target server's load status and the traffic information corresponding to the network service data. Based on the collected real-time data, the particle swarm algorithm is used to quickly and accurately determine the target load allocation strategy. This enables the target load allocation strategy to quickly adapt to dynamic changes in server load and network traffic fluctuations, ensuring stable and efficient system operation under various conditions. This guarantees the efficiency and accuracy of load balancing and improves the processing effect of network service data.
[0105] Furthermore, based on the above Figures 1 to 6 The method shown in this specification, along with one or more embodiments, also provides a computer program product including a computer program that, when executed by a processor, performs the following process: Receive load balancing requests for network service data; In response to the load regulation request, a target server corresponding to the network service data is determined, and a particle swarm corresponding to the target server is constructed, wherein the particles in the particle swarm are used to characterize the load distribution strategy. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated, and the fitness value of the particle during the iteration process is determined according to the updated position information, the load status of the target server, and the service type of the network service data. Based on the fitness value of the particle, the global optimal position of the particle swarm during the iteration process is determined, and when the iteration update ends, the target load allocation strategy is determined and executed based on the global optimal position of the particle swarm.
[0106] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the above-described embodiment of a computer program product is relatively simple in description because it is fundamentally similar to the method embodiment; relevant parts can be referred to the description of the method embodiment.
[0107] This specification provides a computer program product that receives a load balancing request for network service data. In response to the request, it determines the target server corresponding to the network service data and constructs a particle swarm corresponding to the target server. The particles in the particle swarm represent the load allocation strategy. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated. Based on the updated position information, the load status of the target server, and the service type of the network service data, the fitness value of each particle during the iteration process is determined. Based on the fitness value of each particle, the globally optimal position of the particle swarm during the iteration process is determined. Upon completion of the iteration update, the target load allocation strategy is determined and executed based on the globally optimal position of the particle swarm. This allows for real-time collection of the target server's load status and the traffic information corresponding to the network service data. Based on the collected real-time data, the particle swarm algorithm is used to quickly and accurately determine the target load allocation strategy. This allows the target load allocation strategy to quickly adapt to dynamic changes in server load and network traffic fluctuations, ensuring stable and efficient system operation under various conditions. This guarantees the efficiency and accuracy of load balancing and improves the processing effect of network service data.
[0108] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.
[0109] In the 1990s, improvements to a technology could be clearly distinguished as either hardware improvements (e.g., improvements to the circuit structure of diodes, transistors, switches, etc.) or software improvements (improvements to the methodology). However, with technological advancements, many methodological improvements today can be considered direct improvements to the hardware circuit structure. Designers almost always obtain the corresponding hardware circuit structure by programming the improved methodology into the hardware circuit. Therefore, it cannot be said that a methodological improvement cannot be implemented using hardware physical modules. For example, a Programmable Logic Device (PLD) (such as a Field Programmable Gate Array (FPGA)) is such an integrated circuit whose logic function is determined by the user programming the device. Designers can program and "integrate" a digital system onto a PLD themselves, without needing chip manufacturers to design and manufacture dedicated integrated circuit chips. Furthermore, nowadays, instead of manually manufacturing integrated circuit chips, this programming is mostly implemented using "logic compiler" software. Similar to the software compiler used in program development, the original code before compilation must also be written in a specific programming language, called a Hardware Description Language (HDL). There are many HDLs, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, and RHDL (Ruby Hardware Description Language). Currently, the most commonly used are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art should also understand that by simply performing some logic programming on the method flow using one of these hardware description languages and programming it into an integrated circuit, the hardware circuit implementing the logical method flow can be easily obtained.
[0110] The controller can be implemented in any suitable manner. For example, it can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicon Labs C8051F320. A memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also recognize that, in addition to implementing the controller in purely computer-readable program code form, the same functionality can be achieved by logically programming the method steps to make the controller take the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers. Therefore, such a controller can be considered a hardware component, and the means included therein for implementing various functions can also be considered as structures within the hardware component. Alternatively, the means for implementing various functions can be considered as both software modules implementing the method and structures within the hardware component.
[0111] Those skilled in the art will understand that the embodiments of this specification can be provided as methods, systems, or computer program products. Therefore, one or more embodiments of this specification may take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, one or more embodiments of this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0112] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable fraud device to operate in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0113] These computer program instructions can also be loaded onto a computer or other programmable device, causing a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable device for implementing the process. Figure 1One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0114] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0115] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0116] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0117] One or more embodiments of this specification can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a particular task or implement a particular abstract data type. One or more embodiments of this specification can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.
[0118] The above description is merely an embodiment of this specification and is not intended to limit this document. Various modifications and variations can be made to this specification by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims of this specification.
Claims
1. A load regulation method, characterized in that, The method includes: Receive load balancing requests for network service data; In response to the load regulation request, a target server corresponding to the network service data is determined, and a particle swarm corresponding to the target server is constructed, wherein the particles in the particle swarm are used to characterize the load distribution strategy. Based on a dynamic learning factor, the velocity and position of the particle swarm are iteratively updated, and the fitness value of the particle during the iteration process is determined according to the updated position information, the load status of the target server, and the service type of the network service data. Based on the fitness value of the particle, the global optimal position of the particle swarm during the iteration process is determined, and when the iteration update ends, the target load allocation strategy is determined and executed based on the global optimal position of the particle swarm.
2. The method according to claim 1, characterized in that, The iterative update of the velocity and position of the particle swarm based on a dynamic learning factor includes: Based on the iteration stage to which the current iteration number belongs, determine the inertia weight, the first learning factor, and the second learning factor corresponding to the current iteration number. The iteration stage includes a first stage and a second stage. The inertia weight corresponding to the first stage is greater than the inertia weight corresponding to the second stage. The first learning factor is greater than the second learning factor in the first stage and less than the second learning factor in the second stage. Based on the inertia weight, the first learning factor, and the second learning factor corresponding to the current iteration number, the velocity of the particle swarm is updated to obtain the velocity corresponding to the current iteration number. The first learning factor is used to characterize the degree of learning from the particle's own historical best position, and the second learning factor is used to characterize the degree of learning from the global best position of the particle swarm. The position of the particle swarm is updated based on the velocity corresponding to the current iteration number and the position of the particle swarm corresponding to the previous iteration number.
3. The method according to claim 1, characterized in that, The step of determining the fitness value of each particle in the particle swarm during the iteration process based on the updated location information, the load status of the target server, and the service type of the network service data includes: Based on the updated position information, the position information of each particle is determined, and the position information is used to characterize the proportion of requests that the particle is allocated to the server; Based on the position information of each particle and the load status of the target server, a server load assessment value is determined; Under the load distribution strategy corresponding to the globally optimal position at the current iteration number, obtain the type proportion of network service data for each service type, and the average distribution ratio for each service type; Based on the aforementioned type proportions and average distribution proportions, the business type allocation ratio is determined; Based on the server load assessment value and the business type allocation ratio, the fitness value corresponding to each particle in the particle swarm is determined in the current iteration number.
4. The method according to claim 1, characterized in that, The step of determining the global optimal position of the particle swarm during the iteration process based on the fitness value of the particle includes: Based on the fitness value of each particle in the current iteration and the optimal fitness value of each particle in the historical iterations, determine the optimal fitness value of each particle in the current iteration. Based on the optimal fitness value of each particle in the current iteration, the global optimal fitness value of the particle swarm in the current iteration is determined, and the position information of the particle corresponding to the global optimal fitness value is determined as the global optimal position of the particle swarm in the current iteration.
5. The method according to claim 1, characterized in that, Receiving load regulation requests for network service data includes: Obtain the load status of the target server and the network service data; Based on the load status of the target server and / or the network service data, determine whether the load regulation requirements are met, and if the load regulation requirements are met, trigger a load regulation request for the network service data.
6. The method according to claim 5, characterized in that, The step of determining whether the load regulation requirements are met based on the load status of the target server and / or the network service data includes: If any of the target servers has a CPU utilization rate higher or lower than a preset utilization threshold, then the load control requirement is determined to be met; or, If the increase in the network service data exceeds a preset increase threshold, and / or the distribution of the service types of the network service data changes, then the load regulation requirement is determined to be met.
7. A load regulation device, characterized in that, The device includes: The request receiving module is used to receive load regulation requests for network service data. A particle construction module is used to respond to the load control request, determine the target server corresponding to the network service data, and construct a particle swarm corresponding to the target server. The particles in the particle swarm are used to characterize the load distribution strategy. The iterative update module is used to iteratively update the velocity and position of the particle swarm based on a dynamic learning factor, and determine the fitness value of the particle during the iteration process according to the updated position information, the load status of the target server, and the service type of the network service data. The strategy execution module is used to determine the global optimal position of the particle swarm during the iteration process based on the fitness value of the particle, and to determine and execute the target load allocation strategy based on the global optimal position of the particle swarm after the iteration update ends.
8. A load regulation device, characterized in that, It includes a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the computer program, when executed by the processor, implements the steps of the load control method as described in any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, A computer program is stored on the computer-readable storage medium, which, when executed by a processor, implements the steps of the load control method as described in any one of claims 1 to 6.
10. A computer program product, characterized in that, Includes a computer program that, when executed by a processor, implements the steps of the load control method according to any one of claims 1 to 6.