A method for deploying power grid services based on the operating frequency of service chips

By using the greedy service orchestration algorithm of fine-grained image splitting and the non-dominated genetic algorithm frequency modulation model in the smart grid, the working frequency of the server chip is dynamically adjusted, which solves the problem that the energy consumption of the server operating network and the service efficiency cannot be optimized in parallel, and achieves More energy efficient and more responsive MEC services.

CN118642859BActive Publication Date: 2025-01-21湖北省楚天云有限公司 +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411114363.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-14
Publication Date
2025-01-21
Estimated Expiration
2044-08-14

AI Technical Summary

Technical Problem

In the prior art, the energy consumption and service efficiency of server operation network cannot be optimized in parallel, making it difficult to achieve higher energy efficiency and more timely response MEC services in industrial application scenarios such as smart grids.

Method used

By obtaining the collection of the user request chain at the peak and non -peak hours, the greedy service compilation method of a fine -grained mirror is optimized to optimize the initial deployment of the service mirror, combined with non -dominant sorting multi -target optimization of genetic algorithm and dynamic voltage frequency adjustment adjustment , Dynamically adjust the operating frequency of the server chip to optimize the system's energy consumption and service response delay.

Benefits of technology

It achieves a significant reduction in the overall energy consumption of the system while meeting the service response efficiency, improves the network's data processing and request response efficiency, and reduces the end-to-end request delay.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118642859B_ABST
    Figure CN118642859B_ABST
Patent Text Reader

Abstract

The present invention relates to a power grid service deployment method based on the operating frequency of a service chip, comprising: obtaining an initial deployment result of a service image based on a greedy service orchestration algorithm optimization model of fine-grained image splitting; obtaining a request routing decision through a model of a non-dominated sorting multi-objective optimization genetic algorithm according to the computing power of a server chip core and the initial deployment result of the service image, and obtaining a server operating frequency decision by using a dynamic voltage and frequency adjustment method; deriving the service best image deployment result and routing decision in a smart grid during a peak period of concurrent service requests through a greedy service orchestration algorithm optimization model based on fine-grained image splitting, dynamically adjusting the operating frequency of the server chip according to the arrival of service requests under non-peak conditions through a non-dominated sorting multi-objective optimization genetic algorithm, and reducing the overall energy consumption of the system while ensuring the efficiency of data processing and request response of a smart grid service platform.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of mobile edge computing technology, and in particular to a power grid service deployment method based on the operating frequency of a service chip. Background Art

[0002] With the explosive development of the Internet of Things and 5G technologies, more and more application scenarios require real-time processing of large amounts of data, and the traditional cloud computing model is no longer sufficient to meet the growing needs of users. Against this backdrop, edge computing technology has emerged. Edge computing is a distributed computing model that offloads computing resources and services that need to be processed to edge devices as close to users and data as possible, so that users' service requests can be responded to more quickly, data latency and network congestion in cloud-edge transmission can be reduced, and system efficiency can be improved. It has been widely used in the fields of power Internet of Things and Internet of Vehicles.

[0003] However, the computing and storage resources of edge servers are difficult to meet the real-time processing requirements of traditional monolithic software (VNF), so major manufacturers have turned to microservice architecture, which has become an important part of enterprise-level application development. The core of the microservice architecture is to reshape the application architecture into relatively small, functionally independent and data-interoperable small services while ensuring the original application functions. Each microservice only focuses on completing a specific business function and interacts through unified communication specifications. With the help of container-based technology, microservice-based applications can be easily deployed on edge servers. The independence and dynamic adjustment characteristics of microservice instances enable it to effectively adjust the number of instances according to service needs, thereby playing a significant role in reducing network energy consumption.

[0004] At present, there are many papers on edge computing architecture, most of which focus on the deployment of microservices, ignoring the routing of user requests, an important part of the data communication process, and the inherent coupling between them. Some work also explores the request routing or scheduling issues in depth, but ignores the challenges of instance deployment. The above studies mostly focus on the completion efficiency of services, including parameters such as response delay, deployment cost, and service success rate. However, in industrial-level application scenarios such as smart grids, operating costs represented by energy consumption are also important factors that cannot be ignored. Especially during peak operation and stable operation, there is a big difference between the magnitude of requests and the required computing resources. The constant pursuit of extreme network service delay often leads to excessive use of resources and large consumption of energy. Therefore, how to solve the multi-objective optimization problem of reducing energy consumption and service response delay to meet the needs of mobile network users while achieving more flexible and responsive MEC (Multi-access Edge Computing) services that change with time while reducing energy consumption costs is undoubtedly an urgent problem to be solved. Summary of the invention

[0005] The present invention aims at the technical problems existing in the prior art and provides a method for deploying power grid services based on the operating frequency of service chips, which solves the problem that the network energy consumption and service efficiency of the existing servers cannot be optimized in parallel and cannot reach the global optimum. It ultimately realizes the technical problem of MEC services with higher energy efficiency and more timely response.

[0006] According to a first aspect of the present invention, a method for deploying a power grid service based on an operating frequency of a service chip is provided, comprising:

[0007] Step 1: Obtain the set of pending user request chains during peak hours, and obtain the initial deployment result of the service image based on the greedy service orchestration algorithm optimization model of fine-grained image splitting;

[0008] Step 2, obtain the set of pending user request chains during non-peak hours, obtain the request routing decision through the model of non-dominated sorting multi-objective optimization genetic algorithm according to the computing power of the server chip core and the initial deployment result of the service image, and obtain the server operating frequency decision using the dynamic voltage and frequency adjustment method.

[0009] Based on the above technical solution, the present invention can also make the following improvements.

[0010] Optionally, the step 1 includes:

[0011] Step 101, obtaining server resource information for computing in a smart grid scenario during peak hours; the server resource information includes: the number of server nodes, the number of processor chips deployed in the server nodes, and the communication speed between the server nodes;

[0012] Step 102, calculating the computing resource requirement of each microservice in each user request according to the request arrival rate of each user request in the user request chain set and the type of microservice;

[0013] Step 103, sort all undeployed microservices in descending order of their computing resource requirements, and based on the server resource information used for computing, sequentially allocate the microservices requested by the user to the deployed microservice nodes to obtain the initial deployment result of the microservice image.

[0014] Optionally, the calculation formula for the computing resource requirement of the microservice in step 102 is:

[0015] ;

[0016] In the formula, Representing microservices The computing resource requirements, Representing microservices Process the request stream within the maximum delay The computing resources required, Represents the request flow A collection of all microservices;

[0017] By minimum change To determine, the constraint inequality of the minimum change is:

[0018]

[0019] In the formula, express Microservices in Queuing Systems The average queuing delay is Representing microservices The maximum delay rate in the corresponding request flow, Represents the request flow The maximum delay limit is Representation Server The communication delay between them.

[0020] Optionally, step 103 includes:

[0021] Step 10301, initialize the list of undeployed microservices , an array of server nodes that have been used , Idle server nodes , any server node The collection of available computing resources and server nodes that satisfy resource placement constraints ;

[0022] Step 10302: List the microservices Each microservice in the system needs computing resources according to its requirements Sort in descending order;

[0023] Step 10303, if If not empty, get The first microservice with the largest computing resource requirements ; Initialize and clear the collection , traverse the array that has been used Server nodes in ,satisfy When Add to collection middle;

[0024] Step 10304, if the collection If it is still empty, then traverse the array Server nodes in , if the node Satisfy constraints or , then the node Join In the set; if none of them are satisfied, re-execute step 10301;

[0025] Step 10303, set All server nodes in Sort in descending order;

[0026] Step 10304, set Server nodes in To traverse:

[0027] like , then the microservice Fully deployed on server nodes , update deployment and occupation , and microservices from Remove from the list if From Then the server Move to , then jump out of the loop;

[0028] like , then split the microservices Some images are deployed on server nodes , update deployment and occupation ,like From , then the server Add to and from Remove and update the computing resource requirements of the microservice , the update formula is: ;

[0029] like , then the microservice Re-enter the list of microservices that are not selected for deployment and update the computing resource requirements;

[0030] Step 10305: Update the set of available computing resource margins of the node , returns a two-dimensional array set of each microservice deployment result, the two-dimensional array set includes: flag microservice In the service node Binary variable for deployment status on and computing resource usage .

[0031] Optionally, the step 2 includes:

[0032] Step 201, updating the operating frequency of the current server chip to obtain the updated processing capacity of the current server node chip;

[0033] Step 202, iterating the routing decision in real time by using a non-dominated sorting multi-objective optimization genetic algorithm, and dynamically updating the operating frequency of the server chip by using dynamic voltage and frequency adjustment according to the adjustment of the routing decision, so as to meet the requirements of the service node processing capacity difference weight;

[0034] Step 203, construct a comprehensive evaluation function according to the processing capacity difference weight and a multi-objective optimization method based on energy consumption and delay, update the operating frequency of the service image on the node according to the comprehensive evaluation function, and obtain the working frequency decision of the server node.

[0035] Optionally, the comprehensive evaluation function in step 203 is:

[0036] ;

[0037] ;

[0038] ;

[0039] ;

[0040] ;

[0041] ;

[0042] ;

[0043] in, is the total thermal design power consumption of the smart grid system, is the sum of the total response delays of service requests processed by the system, is the weight set, It represents the response delay of processing a single stream of service request r. To process user requests The maximum tolerable delay, For service nodes The operating frequency decisions of currently deployed processor chips, For service nodes The static power consumption, For Server Resource utilization, For service nodes The power consumption factor is determined by physical parameters such as the overall equivalent load capacitance and voltage. For service nodes of computing resources, Represents a server node Handling microservices under certain working conditions service capabilities, including Represents the server to the microservice The unit processing capacity, For server chips at a certain operating frequency And the resource utilization of each server node after FGIS-GSOA deployment Deploy the service image and run it on the service node Processing user requests on the chip core The processing power consumption generated when

[0044] Optionally, step 202 includes:

[0045] Step 2201, exploring the solution space by random routing, using the solution space as the initial parent solution set for routing decision, and calculating the corresponding evaluation value based on the comprehensive evaluation function;

[0046] Step 2202, based on the server chip operating frequency obtained by the generated routing decision calculation, the binary tournament method is used to select the results in the parent solution set in pairs to perform multi-point crossover and exchange mutation operations, and the frequency of each node is increased or decreased from the current frequency gear to the new frequency under the artificially set mutation probability to obtain the child solution set;

[0047] Step 2203, using the evaluation value and the success rate as indicators to perform non-dominated sorting on the child solution set and the parent solution set, and classifying the child solution set and the parent solution set according to the Pareto dominance relationship and assigning them to different Pareto levels;

[0048] Step 2204, based on the selection of the congestion calculation, the elite retention strategy is used to continue the solution that takes into account both delay and energy consumption in each generation of solution set in the genetic algorithm;

[0049] Step 20205, using the parent solution set to repeatedly generate a new child solution set, iteratively generating frequency modulation and routing decision results that meet the target.

[0050] Optionally, the step 20204 includes:

[0051] For the routing of user request flows between nodes, the request flows Microservices passed At the node The probability of the above treatment is defined as ;

[0052] For non-initial microservices in the request flow, Microservices from access Communication link selection The forwarding probability The calculation formula is:

[0053]

[0054]

[0055] Based on the type of request flow, the number of server nodes, and the type of microservices, combined with the computing resource usage and microservice types, based on the request arrival rate, microservice type, and latency constraints calculated by the routing array, according to Queuing model, calculate the minimum operating frequency f required by the server chip and store it in the collection middle;

[0056] According to the frequency combination results, Sort in descending order and select the maximum value As the current period Node operating frequency, storing the overall server frequency collection middle;

[0057] According to the set server chip operating frequency gear, the collection Round off each frequency element in the , and select the server operating frequency with the lowest energy consumption while ensuring the latency constraint;

[0058] According to the initial deployment results of the microservice image, the type of microservice, and the running frequency of the server node, the processing capacity of each node for each microservice is calculated, combined with the routing probability results and communication delay of the microservice request, through The corresponding delay is calculated using the queuing theory formula;

[0059] For a microservice According to the server node The number of instances deployed on And the corresponding service processing rate , calculate the request flow in the corresponding queueing network At the node Processing microservices Required processing delay ;

[0060] According to the distributed deployment results of microservices in the service request flow, the communication delay between nodes in the routing process is calculated.

[0061] Optional, total request latency in the service network and a single request stream Request latency The calculation formula is:

[0062] ;

[0063] .

[0064] Optionally, the step 20204 includes:

[0065] According to the Pareto frontier where the solution strategy is located, the crowding distance of each solution is calculated based on the relative position of the solution in the target space, and the difference between each solution and the worst and best target values ​​in the frontier is compared to obtain the crowding contribution of each solution strategy, and the change rate of the crowding contribution between two adjacent solutions is calculated. The change rate is the crowding index , and its calculation formula is:

[0066] ;

[0067] ;

[0068] ;

[0069] According to the order of crowding within each group of Pareto frontiers, solutions with higher crowding are selected to be inherited to the next generation.

[0070] The present invention provides a method for deploying power grid services based on the operating frequency of a service chip. First, a set of pending service requests and network resource configuration are determined under a smart grid network during peak hours. Then, according to the smart grid network node resource information and the set of pending user requests, a greedy service orchestration algorithm optimization model based on fine-grained image splitting is used to obtain the deployment status of the service instance under peak conditions and the preliminary request routing decision. Then, according to the core processing capacity of the server chip and the deployment status of the service instance when any non-peak request flow arrives, the working frequency decision of the server chip is obtained through a non-dominated genetic algorithm frequency modulation model. Finally, the routing decision of the request flow in any non-peak period is updated according to the updated working frequency decision. The present invention derives the optimal static deployment and routing decision of microservices in a network under a high-voltage working environment through a greedy service orchestration algorithm optimization model based on fine-grained image splitting, and dynamically adjusts the chip working frequency through a non-dominated genetic algorithm frequency modulation model to optimize system energy consumption.

[0071] In the embodiment of the present invention, by adopting the method of joint optimization of service deployment and frequency modulation routing, not only can the efficiency of network data processing and request response be improved and end-to-end request delay be reduced, but also the overall energy consumption of the system can be minimized. BRIEF DESCRIPTION OF THE DRAWINGS

[0072] Figure 1 A flowchart of a smart grid service deployment method provided by an embodiment of the present invention;

[0073] Figure 2 A schematic diagram of a network structure of an embodiment of a method for deploying power grid services based on the operating frequency of a service chip provided by the present invention;

[0074] Figure 3 A flow chart of a non-dominated sorting combined routing frequency modulation algorithm provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0075] The principles and features of the present invention are described below in conjunction with the accompanying drawings. The examples given are only used to explain the present invention and are not used to limit the scope of the present invention.

[0076] Figure 1 A flowchart of a method for deploying power grid services based on the operating frequency of a service chip provided by the present invention. Figure 2A schematic diagram of a network structure of an embodiment of a method for deploying power grid services based on the operating frequency of a service chip provided by the present invention, Figure 3 A flow chart of a non-dominated sorting combined routing frequency modulation algorithm provided by an embodiment of the present invention, combined with Figure 1-Figure 3 It can be seen that the method includes:

[0077] Step 1: Obtain the set of pending user request chains during peak hours, and obtain the initial deployment result of the service image based on the greedy service orchestration algorithm optimization model with fine-grained image splitting.

[0078] Step 2: Obtain the set of pending user request chains during off-peak hours. Based on the computing power of the server chip core and the initial deployment results of the service image, obtain the request routing decision through the model of the multi-objective optimization genetic algorithm of non-dominated sorting, and use the dynamic voltage and frequency adjustment method to obtain the server operating frequency decision, so as to optimize the energy consumption of the overall system while taking into account the service efficiency.

[0079] The present invention provides a power grid service deployment method based on the operating frequency of a service chip. The method derives the optimal image deployment result and routing decision of services in a smart grid during peak hours of concurrent service requests through a greedy service orchestration algorithm optimization model based on fine-grained image splitting. The multi-objective optimization genetic algorithm of non-dominated sorting dynamically adjusts the operating frequency of the server chip according to the arrival of service requests under non-peak conditions. Under the premise of ensuring the efficiency of data processing and request response of the smart grid service platform, the overall energy consumption of the system is reduced.

[0080] Example 1

[0081] Embodiment 1 provided by the present invention is an embodiment of a grid service deployment based on the service chip operating frequency provided by the present invention, combined with Figure 1-Figure 3 It can be seen that the embodiment of the method includes:

[0082] Step 1: Obtain the set of pending user request chains during peak hours, and obtain the initial deployment result of the service image based on the greedy service orchestration algorithm optimization model with fine-grained image splitting.

[0083] In a specific implementation, the to-be-processed user request chain set includes a request chain set from the service side and the user side. The request chain set from the service side and the user side may include:

[0084] The collection of request chains from the service side and the user side sent to the smart grid service center is defined as , for any user request ,in , indicating that for The service request passes through the i-th service, express The request arrival rate of service requests conforms to the Poisson distribution. express The maximum tolerable delay of service requests. In peak conditions, the arrival rate of requests to access the server is the highest. In the remaining non-peak time period, the arrival rate of service requests will only reach a part of the peak arrival rate, and the arrival rate of different service requests in different time periods will also fluctuate. Therefore, it is necessary to control the service intensity of each node deployed microservice in real time according to each time period.

[0085] In a possible implementation manner, step 1 includes:

[0086] Step 101, obtaining server resource information used for computing in a smart grid scenario during peak hours; the server resource information includes: the number of server nodes, the number of processor chips deployed in the server nodes, and the communication speed between server nodes.

[0087] In specific implementation, a large number of server nodes, namely resource centers, are distributed in the smart grid service network. A certain number of processor chips are deployed in each server node. Whenever a service instance is deployed on a node, a certain amount of computing resources of the node will be consumed.

[0088] Any server node ,definition Represents the computing resources of the server chip numbered i, which is equivalent to the ability of the node to deploy service images.

[0089] The communication link between any two nodes , represents the node and The communication links between . ,in Representation Node and The bandwidth between Representation Node and The communication delay between unit request flows.

[0090] Step 102, in the default highest frequency operation mode, the computing resource requirements of each microservice in each user request are calculated according to the request arrival rate of each user request in the user request chain set and the type of microservice.

[0091] In a possible implementation manner, the calculation formula for the computing resource requirements of the microservice in step 102 is:

[0092] .

[0093] In the formula, Representing microservices The computing resource requirements, Representing microservices Process the request stream within the maximum delay The computing resources required to process user requests increase with increases with the increase of Represents the request flow A collection of all microservices.

[0094] By minimum change To determine, the constraint inequality of the minimum change is:

[0095]

[0096] In the formula, express Microservices in Queuing Systems The average queuing delay is Representing microservices The maximum delay rate in the corresponding request flow, Represents the request flow The maximum delay limit is Representation Server The communication delay between them.

[0097] Step 103, sort all undeployed microservices in descending order of their computing resource requirements, and allocate the microservices requested by the user to the deployed microservice nodes in order based on the server resource information used for computing, to obtain the initial deployment result of the microservice image.

[0098] In a possible implementation manner, step 103 includes: obtaining each microservice Computing resource requirements ,according to Size vs. Microservices Sort by the number of required instances in descending order, with the goal of prioritizing The amount of computing resources required , each time a microservice is performed If the image is deployed, update the collection , reorder the computing resource requirements. Each time an image is deployed, the computing resource requirements are reordered.

[0099] In the specific deployment process, combined with the constraints of deployable resources of server nodes, server nodes that meet the constraints are found from the nodes where microservices have been deployed, and added to the set of server nodes that can be deployed by the current microservice;

[0100] If the deployed server nodes do not meet the constraints, and the set of undeployed server nodes is not empty, select the server nodes that meet the constraints from the set of undeployed server nodes. Deploy the current microservice on a service node that has the following conditions and has a smaller average communication delay with the previous microservice deployment node. Represents the computing resources available to the server node.

[0101] If there is no node that meets the constraint among the server nodes that have been deployed, and the set of server nodes that have not been deployed is empty, select the node that meets the constraint from the server nodes that have not participated in the deployment. The server nodes with constraint inequalities are used to deploy microservices.

[0102] According to the fine-grained deployment plan, The split constraint inequality during deployment is as follows:

[0103] .

[0104] .

[0105] in Represents the split factor, which is used to control the degree of fine-grained split deployment of server node computing resources. Microservices In the service node The deployment situation on If it is 1, it means microservice There is an image deployed on the node If it is 0, there is no deployment.

[0106] When deploying the first phase of microservice images, the server chip operates at the highest frequency by default, that is, the mode with the strongest processing power, because it is necessary to cope with the peak service arrival rate.

[0107] In order to assist with deployment and update the deployment status of each server node and microservice in real time, Used to represent the server nodes where microservices are deployed. Indicates a server node that has not been deployed. Extracting microservices ,according to The constraint inequality from Find a server node that meets the requirements , add it to the satisfying microservice A collection of server nodes that compute resource constraints If There is no server node that satisfies the split constraint inequality and If not empty, then switch to Choose to meet Service nodes with low average communication delay are used to deploy microservices ;like is still an empty set, then Satisfied The server node of the split constraint inequality is added to In this step, we will split the currently deployed microservices into parts and deploy them in the first step.

[0108] After screening is completed After that, from the current microservice of Select a server node and check whether the available computing resources of the node are less than the resources required by the microservice. If so, deploy all the images required by the microservice to the selected server node. Otherwise, split the service images required by the microservice at once and select them to be deployed to The middle node is a server node with more available computing resources;

[0109] Repeat the above steps to deploy the microservice image to the server node, and end the loop when there is no node that meets the deployment conditions;

[0110] When the available capacity of computing resources of each server node is less than the computing resources required by the microservice after a split, the microservice is added to the Waiting for the next round of deployment.

[0111] from Select The most server nodes are checked first Is it not less than , if less than Microservices All the required images are deployed on the server node, otherwise the microservice The required service images are split twice and deployed to larger On the server nodes that have not been Move to ; Loop this process until no available server nodes are assigned; if , that is, the impact of microservices If it cannot be fully allocated, the microservice Add as a new microservice node to Waiting for the next round of deployment.

[0112] Specifically, the code implementation process of step 103 includes:

[0113] Step 10301, initialize the list of undeployed microservices , an array of server nodes that have been used , Idle server nodes , any server node The collection of available computing resources and server nodes that satisfy resource placement constraints .

[0114] Step 10302, microservice list Each microservice in the system needs computing resources according to its requirements Sort in descending order.

[0115] Step 10303, if If not empty, get The first microservice with the largest computing resource requirements ; Initialize and clear the collection , traverse the array that has been used Server nodes in ,satisfy When Add to collection middle.

[0116] Step 10304, if the collection If it is still empty, then traverse the array Server nodes in , if the node Satisfy constraints or , then the node Join In the set; if none of them are satisfied, re-execute step 10301.

[0117] Step 10303, set All server nodes in Sort in descending order.

[0118] Step 10304, set Server nodes in To traverse:

[0119] like , then the microservice Fully deployed on server nodes , update deployment and occupation , and microservices from Remove from the list if From Then the server Move to , then jump out of the loop.

[0120] like , then split the microservices Some images are deployed on server nodes , update deployment and occupation ,like From , then the server Add to and from Remove and update the computing resource requirements of the microservice , the update formula is: .

[0121] like , that is, not fully deployed, the microservice Re-enter the list of microservices that are not selected for deployment , it is considered as a new microservice that needs to be deployed, and the computing resource requirements need to be updated. The value is the updated .

[0122] Step 10305: Update the set of available computing resource margins of the node , returns a two-dimensional array collection of each microservice deployment result, the two-dimensional array collection includes: Flag microservice In the service node Binary variable for deployment status on and computing resource usage .

[0123] Through the greedy service orchestration algorithm based on fine-grained image splitting, we can obtain the microservice image deployment result that can cope with the peak arrival rate, satisfying the high success rate and low response delay of service request responses during peak hours. After that, the working frequency in the non-peak period is dynamically adjusted in different time periods while ensuring the service request delay.

[0124] Step 2: Obtain the set of pending user request chains during off-peak hours. Based on the computing power of the server chip core and the initial deployment results of the service image, obtain the request routing decision through the model of the multi-objective optimization genetic algorithm of non-dominated sorting, and use the dynamic voltage and frequency adjustment method to obtain the server operating frequency decision, so as to optimize the energy consumption of the overall system while taking into account the service efficiency.

[0125] In a possible implementation manner, step 2 includes:

[0126] Step 201, update the operating frequency of the current server chip to obtain the updated processing capacity of the current server node chip.

[0127] Step 202, the routing decision is iterated in real time by a non-dominated sorting multi-objective optimization genetic algorithm, and the working frequency of the server chip is dynamically updated by dynamic voltage and frequency adjustment according to the adjustment of the routing decision to meet the requirements of the difference weight of the processing capacity of the service node.

[0128] In a possible embodiment, step 202 includes:

[0129] Step 20201, explore the solution space by random routing, use the solution space as the initial parent solution set of routing decision, and calculate the corresponding evaluation value based on the comprehensive evaluation function.

[0130] Step 2202, based on the server chip operating frequency obtained by the generated routing decision calculation, use the binary tournament method to select the results in the parent solution set in pairs to perform multi-point crossover and exchange mutation operations, and increase or decrease the frequency of each node from the current frequency gear to a new frequency under a manually set mutation probability to obtain a child solution set.

[0131] Step 2203, using the evaluation value and the success rate as indicators to perform non-dominated sorting on the offspring solution set and the parent solution set, that is, classifying the offspring solution set and the parent solution set according to the Pareto dominance relationship and assigning them to different Pareto levels.

[0132] Step 20204, based on the choice of congestion calculation, the elite retention strategy is used to continue the solution that takes into account both latency and energy consumption in each generation of solution set in the genetic algorithm.

[0133] In a possible implementation manner, step 20204 includes:

[0134] For the routing of user request flows between nodes, the request flows Microservices passed At the node The probability of the above treatment is defined as .

[0135] For non-initial microservices in the request flow, there is a forwarding probability between the communication between the preceding microservice and the current microservice. Microservices from access Communication link selection The forwarding probability The calculation formula is:

[0136] .

[0137] .

[0138] For the global frequency modulation model, according to the type of request flow, the number of server nodes and the type of microservices, a three-dimensional routing array can be constructed to represent the routing scheduling results, combined with the computing resource usage and microservice types, based on the request arrival rate, microservice type, and latency constraints calculated by the routing array, according to Queuing model, calculate the time period , the current server node Access the microservice When the server chip requires the minimum operating frequency f, it is stored in the set middle.

[0139] There is only one operating frequency for the entire server, so each Sort in descending order and take out the maximum value As the current period The node running frequency is stored in the overall server frequency set under the model According to the set server chip operating frequency gear, upward to the collection Each frequency element in is rounded off, and the server operating frequency with the lowest energy consumption is selected under the premise of ensuring the delay constraint. According to the obtained microservice image deployment results, microservice types and server node operating frequencies, the processing capacity of each node for each microservice can be calculated. Combined with the routing probability results of each microservice request and the communication delay between server nodes, The queuing theory formula can be used to calculate the corresponding delay. According to Burke's theorem, in a stable state, the service model can be abstracted as The process of user request service in the queuing system is a Poisson process. The user request flow is the Poisson flow in the queuing network. The service time of the microservice satisfies the exponential distribution. For a microservice According to the server node The number of instances deployed on And the corresponding service processing rate , the corresponding service request delay in the corresponding queuing network can be calculated, and the corresponding request flow At the node Processing microservices The required processing delay is defined as At the same time, the distributed deployment of microservices in the service request flow needs to consider the communication delay between nodes when the request flow routing and forwarding occurs.

[0140] In a possible implementation manner, the total request delay of the service network is and a single request stream Request latency The calculation formula is:

[0141] .

[0142] .

[0143] In a possible implementation manner, step 20204 includes:

[0144] According to the Pareto frontier where the solution strategy is located, the crowding distance of each solution is calculated based on the relative position of the solution in the target space. The crowding contribution of each solution strategy is obtained by comparing the difference between each solution and the worst and best target values ​​in the frontier. The change rate of the crowding contribution between two adjacent solutions is calculated. The change rate is the crowding index , and its calculation formula is:

[0145] .

[0146] .

[0147] .

[0148] According to the non-dominated sorting results and crowding index of the first generation of parent population, the binary tournament based on crowding comparison selects the parent solution strategy participating in the crossover step of the genetic algorithm. For each request flow in the three-dimensional routing strategy, it is necessary to ensure that the sum of the routing probabilities of any microservice in the request chain on each server node is 1 when performing the crossover operation. Therefore, the minimum unit of the array fragment selected for each crossover is the routing strategy of a microservice in the request chain at different nodes. The multi-point crossover method is selected, and multiple crossover points are randomly set in the individual code string. Each crossover point is the starting point of the minimum unit fragment, and then some gene exchanges are performed at a certain exchange probability in the form of interval exchange. Then, mutation operations are performed on each individual of the population to ensure the completeness of the space exploration, maintain the diversity of the population solution, and prevent the optimization algorithm from falling into the local optimum too early. Similarly, in order to maintain the constraints of routing probability and , the swap mutation mode is selected, and only the swap mutation operation is performed between the routing probabilities on each server node within any microservice in the request chain, that is, the traffic routing probability of the current request flow accessing the two server nodes to process the same microservice is swapped. Under a certain mutation probability, the frequency of the current request flow processing the microservice on the two nodes is changed accordingly. Finally, after selection, crossover and mutation operations, a child population of the same size N is generated.

[0149] After the new generation of population is generated, the offspring and parent population sets are merged, and the non-dominated sorting process is repeated for the population of size 2N. At the same time, the parent individuals of the new generation of population of size N are selected according to the crowding rule. First, ensure that all the optimal non-dominated solutions in the first front of Pareto are selected, and then select the solutions of the subsequent front according to the crowding degree of each solution. Solutions with high crowding are more likely to be selected, which helps to maintain the diversity of solution strategies and make the solutions evenly distributed on the Pareto front, and improve the global search strategy of the solution space. At the same time, the elite retention strategy ensures that the optimal non-dominated solutions in the first front of the offspring and the original parent generation are retained in the new generation of population.

[0150] Step 20205, repeatedly generate new child solution sets using the parent solution set, and iteratively generate frequency modulation and routing decision results that meet the target.

[0151] Step 203, construct a comprehensive evaluation function according to the processing capacity difference weight and the multi-objective optimization method based on energy consumption and delay, update the running frequency of the service image on the node according to the comprehensive evaluation function, and obtain the working frequency decision of the server node.

[0152] In a possible implementation method, the energy consumption index and delay index of the smart grid network are integrated to provide a comprehensive evaluation index of the overall model. :

[0153]

[0154] Right now As an optimization indicator in the iterative process of the genetic algorithm of the non-dominated sorting in the embodiment of the present invention, the routing probability result with lower energy consumption and faster response delay will be continued to the offspring population by the elite retention strategy.

[0155] In the specific routing and frequency modulation decision process, random routing and frequency modulation are used to generate an even array of initial individuals as the first generation parent population of the genetic algorithm while ensuring the arrival rate constraint. The population size is , each individual represents a set of routing strategies. According to the arrival rate of each request flow, the minimum frequency gear required by each microservice on each node can be calculated. , according to the statistical frequency table of each node , select the largest frequency gear in the table As a dynamic frequency adjustment strategy, the delay of each individual strategy is calculated based on the routing frequency adjustment results. And energy consumption As a result, the maximum tolerable delay constraint can be Calculate the average service success rate of the request flow ; Calculate the evaluation function according to the formula of comprehensive evaluation index And the success rate indicator Perform a fast non-dominated sort on the population set and calculate the dominated count of each solution strategy according to two sets of indicators and the dominating set , taking into account higher evaluation functions and success rate The solution strategies are on the first Pareto frontier because they are not easily dominated by other solutions, and these solution strategies are removed from the solution set. Repeat this process and recalculate the dominated counts of the remaining strategies in the solution set. and the dominating set , and then distribute the remaining solution strategies to the subsequent Pareto frontiers.

[0156] The comprehensive evaluation function in step 203 is:

[0157] .

[0158] .

[0159] .

[0160] .

[0161] .

[0162] .

[0163] .

[0164] in, is the total thermal design power consumption (TDP) of the smart grid system. is the sum of the total response delays of service requests processed by the system, is the weight set, It represents the response delay of processing a single stream of service request r. To process user requests The maximum tolerable delay, For service nodes The operating frequency decision of the currently deployed processor chip: 1 is downclocking, 2 is main frequency, and 3 is overclocking, which corresponds to the actual operating frequency of different chip models. For service nodes The static power consumption, For Server Resource utilization, For service nodes The power consumption factor is determined by physical parameters such as the overall equivalent load capacitance and voltage. For service nodes of computing resources, Represents a server node Handling microservices under certain working conditions service capabilities, including Represents the server to the microservice The unit processing capacity, For server chips at a certain operating frequency And the resource utilization of each server node after FGIS-GSOA deployment Deploy the service image and run it on the service node Processing user requests on the chip core The processing power consumption generated when

[0165] The embodiment of the present invention provides a method for deploying power grid services based on the operating frequency of a service chip. First, a set of pending service requests and network resource configuration are determined under a smart grid network during peak hours. Then, according to the smart grid network node resource information and the set of pending user requests, a greedy service orchestration algorithm optimization model based on fine-grained image splitting is used to obtain the deployment status of the service instance under peak conditions and the preliminary request routing decision. Then, according to the core processing capacity of the server chip and the deployment status of the service instance when any non-peak request flow arrives, the working frequency decision of the server chip is obtained through a non-dominated genetic algorithm frequency modulation model. Finally, the routing decision of the request flow in any non-peak period is updated according to the updated working frequency decision. The present invention derives the optimal static deployment and routing decision of microservices in a network under a high-voltage working environment through a greedy service orchestration algorithm optimization model based on fine-grained image splitting, and dynamically adjusts the chip working frequency through a non-dominated genetic algorithm frequency modulation model to optimize system energy consumption.

[0166] In the embodiment of the present invention, by adopting the method of joint optimization of service deployment and frequency modulation routing, not only can the efficiency of network data processing and request response be improved and end-to-end request delay be reduced, but also the overall energy consumption of the system can be minimized.

[0167] It should be noted that in the above embodiments, the description of each embodiment has its own emphasis, and for parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0168] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention 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.

[0169] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded computer, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0170] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0171] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0172] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.

[0173] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A method for deploying power grid services based on the operating frequency of a service chip, characterized in that: The method comprises: Step 1: Obtain the set of pending user request chains during peak hours, and obtain the initial deployment result of the service image based on the greedy service orchestration algorithm optimization model of fine-grained image splitting; Step 2, obtaining a set of pending user request chains during off-peak hours, obtaining a request routing decision through a model of a non-dominated sorting multi-objective optimization genetic algorithm according to the computing power of the server chip core and the initial deployment result of the service image, and obtaining a server operating frequency decision using a dynamic voltage and frequency adjustment method; The step 2 comprises: Step 201, updating the operating frequency of the current server chip to obtain the updated processing capacity of the current server node chip; Step 202, iterating the routing decision in real time by using a non-dominated sorting multi-objective optimization genetic algorithm, and dynamically updating the operating frequency of the server chip by using dynamic voltage and frequency adjustment according to the adjustment of the routing decision, so as to meet the requirements of the service node processing capacity difference weight; Step 203, constructing a comprehensive evaluation function according to the processing capacity difference weight and a multi-objective optimization method based on energy consumption and delay, updating the operating frequency of the service image on the node according to the comprehensive evaluation function, and obtaining an operating frequency decision of the server node; The comprehensive evaluation function in step 203 is: ; ; ; ; ; ; ; in, is the total thermal design power consumption of the smart grid system, is the sum of the total response delays of service requests processed by the system, is the weight set, It represents the response delay of processing a single stream of service request r. To process user requests The maximum tolerable delay, For service nodes The operating frequency decisions of currently deployed processor chips, For service nodes The static power consumption, For Server Resource utilization, For service nodes The power consumption factor is determined by physical parameters such as the overall equivalent load capacitance and voltage. For service nodes of computing resources, Represents a server node Handling microservices under certain working conditions service capabilities, including Represents the server to the microservice The unit processing capacity, For server chips at a certain operating frequency And the resource utilization of each server node after FGIS-GSOA deployment Deploy the service image and run it on the service node Processing user requests on the chip core The processing power consumption generated when 2. The method according to claim 1, characterized in that The step 1 comprises: Step 101, obtaining server resource information for computing in a smart grid scenario during peak hours; the server resource information includes: the number of server nodes, the number of processor chips deployed in the server nodes, and the communication speed between the server nodes; Step 102, calculating the computing resource requirement of each microservice in each user request according to the request arrival rate of each user request in the user request chain set and the type of microservice; Step 103, sort all undeployed microservices in descending order of their computing resource requirements, and based on the server resource information used for computing, sequentially allocate the microservices requested by the user to the deployed microservice nodes to obtain the initial deployment result of the microservice image.

3. The method according to claim 2, characterized in that The calculation formula for the computing resource requirements of the microservice in step 102 is: ; In the formula, Representing microservices The computing resource requirements, Representing microservices Process the request stream within the maximum delay The computing resources required, Represents the request flow A collection of all microservices; By minimum change To determine, the constraint inequality of the minimum change is: In the formula, express Microservices in Queuing Systems The average queuing delay is Representing microservices The maximum delay rate in the corresponding request flow, Represents the request flow The maximum delay limit is Representation Server The communication delay between them.

4. The method according to claim 2, characterized in that: The step 103 comprises: Step 10301, initialize the list of undeployed microservices , an array of server nodes that have been used , Idle server nodes , any server node The collection of available computing resources and server nodes that satisfy resource placement constraints ; Step 10302: List the microservices Each microservice in the system needs computing resources according to its requirements Sort in descending order; Step 10303, if If not empty, get The first microservice with the largest computing resource requirements ; Initialize and clear the collection , traverse the array that has been used Server nodes in ,satisfy When Add to collection middle; Step 10304, if the collection If it is still empty, then traverse the array Server nodes in , if the node Satisfy constraints or , then the node Join In the set; if none of them are satisfied, re-execute step 10301; Step 10303, set All server nodes in Sort in descending order; Step 10304, set Server nodes in To traverse: like , then the microservice Fully deployed on server nodes , update deployment and occupation , and microservices from Remove from the list if From Then the server Move to , then jump out of the loop; like , then split the microservices Some images are deployed on server nodes , update deployment and occupation ,like From , then the server Add to and from Remove and update the computing resource requirements of the microservice , the update formula is: ; like , then the microservice Re-enter the list of microservices that are not selected for deployment and update the computing resource requirements; Step 10305: Update the set of available computing resource margins of the node , returns a two-dimensional array set of each microservice deployment result, the two-dimensional array set includes: flag microservice In the service node Binary variable for deployment status on and computing resource usage .

5. The method according to claim 1, characterized in that The step 202 comprises: Step 2201, exploring the solution space by random routing, using the solution space as the initial parent solution set for routing decision, and calculating the corresponding evaluation value based on the comprehensive evaluation function; Step 2202, based on the server chip operating frequency obtained by the generated routing decision calculation, the binary tournament method is used to select the results in the parent solution set in pairs to perform multi-point crossover and exchange mutation operations, and the frequency of each node is increased or decreased from the current frequency gear to the new frequency under the artificially set mutation probability to obtain the child solution set; Step 2203, using the evaluation value and the success rate as indicators to perform non-dominated sorting on the child solution set and the parent solution set, and classifying the child solution set and the parent solution set according to the Pareto dominance relationship and assigning them to different Pareto levels; Step 2204, based on the selection of the congestion calculation, the elite retention strategy is used to continue the solution that takes into account both delay and energy consumption in each generation of solution set in the genetic algorithm; Step 20205, using the parent solution set to repeatedly generate a new child solution set, iteratively generating frequency modulation and routing decision results that meet the target.

6. The method according to claim 5, characterized in that The step 20204 includes: For the routing of user request flows between nodes, the request flows Microservices passed At the node The probability of the above treatment is defined as ; For non-initial microservices in the request flow, Microservices from access Communication link selection The forwarding probability The calculation formula is: Based on the type of request flow, the number of server nodes, and the type of microservices, combined with the computing resource usage and microservice types, based on the request arrival rate, microservice type, and latency constraints calculated by the routing array, according to Queuing model, calculate the minimum operating frequency f required by the server chip and store it in the collection middle; According to the frequency combination results, Sort in descending order and select the maximum value As the current period Node operating frequency, storing the overall server frequency collection middle; According to the set server chip operating frequency gear, the collection Round off each frequency element in the , and select the server operating frequency with the lowest energy consumption while ensuring the latency constraint; According to the initial deployment results of the microservice image, the type of microservice, and the running frequency of the server node, the processing capacity of each node for each microservice is calculated, combined with the routing probability results and communication delay of the microservice request, through The corresponding delay is calculated using the queuing theory formula; For a microservice According to the server node The number of instances deployed on And the corresponding service processing rate , calculate the request flow in the corresponding queueing network At the node Processing microservices Required processing delay ; According to the distributed deployment results of microservices in the service request flow, the communication delay between nodes in the routing process is calculated.

7. The method according to claim 6, characterized in that Total request latency of the service network and a single request stream Request latency The calculation formula is: ; 。 8. The method according to claim 5, characterized in that The step 20204 includes: According to the Pareto frontier where the solution strategy is located, the crowding distance of each solution is calculated based on the relative position of the solution in the target space, and the difference between each solution and the worst and best target values ​​in the frontier is compared to obtain the crowding contribution of each solution strategy, and the change rate of the crowding contribution between two adjacent solutions is calculated. The change rate is the crowding index , and its calculation formula is: ; ; ; According to the order of crowding within each group of Pareto frontiers, solutions with higher crowding are selected to be inherited to the next generation.

Citation Information

Patent Citations

  • Micro-service call graph deployment and request routing joint optimization method and system

    CN117097806A

  • Routing decision updating method, system and equipment based on CPU (Central Processing Unit) working frequency

    CN118316860A