Industrial edge network micro-service optimization method based on dynamic arrangement and migration expansion
By abstracting the industrial edge network into an intelligent industrial network model, and utilizing m/m/c queue networks and mixed-integer nonlinear programming to optimize the dynamic scaling and migration of microservice instances, the system solves the response latency problem caused by resource constraints and bandwidth fluctuations, achieves efficient microservice collaborative deployment and request routing, and improves the system's service continuity and energy efficiency.
Patent Information
- Application Number
- CN202511454786.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-13
- Publication Date
- 2025-11-07
- Estimated Expiration
- 2045-10-13
AI Technical Summary
In existing industrial edge networks, due to limited node resources and fluctuating network link bandwidth, dynamic adaptive resource orchestration cannot be achieved, making it difficult to achieve real-time adaptive scheduling of microservice instances while ensuring request response latency.
The industrial edge network is abstracted into an intelligent industrial network model. Real-time statistics are performed through multivariate performance analysis based on m/m/c queue networks and binary search algorithm. Combined with mixed integer nonlinear programming solution, the dynamic scaling and migration expansion of microservice instances are optimized to achieve optimal collaborative deployment and request routing.
It reduces request latency, minimizes resource waste and energy costs, improves system service continuity and overall energy efficiency, and maximizes request success rate.
Smart Images

Figure CN120915666A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of industrial edge network, and more particularly, to an industrial edge network micro-service optimization method and system based on dynamic arrangement and migration expansion, an electronic device and a storage medium. BACKGROUND
[0002] With the rapid development of Internet of Things, 5G and artificial intelligence technology, industrial automation, intelligent manufacturing and industrial Internet of Things have gradually become the core field of new generation information technology application. Industrial edge network, as a key platform for data processing and application deployment, is becoming increasingly important. Industrial edge network architecture is composed of a large number of heterogeneous edge nodes, including a group of edge servers and processing cores, and data transmission is realized through communication links. In this network, application systems are usually based on modular micro-service architecture, which splits complex industrial applications into multiple micro-services with single function, independence and interaction through unified interface, and each micro-service instance is deployed on different edge nodes to cooperatively complete industrial application processing tasks in the form of service graph.
[0003] Traditional cloud computing mode has the disadvantages of high transmission delay and slow response speed when dealing with real-time requirements of industrial sites, and industrial edge computing technology emerges as the times require. However, the production plan, equipment state and various random events in the industrial field make the request flow have strong time-varying and uncertainty, resulting in dynamic changes of the request arrival rate, processing load and resource occupation of each micro-service instance in the system. The existing technology mainly focuses on the joint optimization of micro-service static deployment and request routing, ignoring the cooperative adjustment of micro-service instance core resource scaling and inter-node migration expansion under dynamic conditions. In industrial edge network, node resources are limited and network link bandwidth fluctuates significantly, making it difficult to realize real-time adaptive scheduling of micro-service instances in core configuration and node distribution while ensuring request response time delay. SUMMARY
[0004] The present application provides an industrial edge network micro-service optimization method and system based on dynamic arrangement and migration expansion, an electronic device and a storage medium to solve the problem that the existing industrial edge network cannot realize dynamic adaptive resource arrangement due to limited node resources and network link bandwidth fluctuation.
[0005] According to the first aspect of the present application, an industrial edge network micro-service optimization method based on dynamic arrangement and migration expansion is provided, comprising: S1, abstracting the industrial edge network into an intelligent industrial network model composed of a plurality of heterogeneous edge nodes and links, modeling the industrial application request as a request chain composed of a plurality of micro-services with data dependency relationship based on the intelligent industrial network model, and calculating the micro-service instance deployment scheme and request routing scheme in the request chain; S2, real-time statistics time-varying request flow, using the multi-element performance analysis model based on m / m / c Queue network and binary search algorithm to analyze the minimum core number that meets the delay constraint in the statistical result, and based on the analysis result, dynamically adjusting the core resources of the deployed micro-service instances; S3, according to the preliminary dynamic adjustment result and the migration cost, converting the complex multi-node migration decision problem into a mixed integer nonlinear programming solving problem and solving, and according to the solving result, realizing the optimal cooperative deployment and request routing optimization of the micro-service instances between the edge nodes.
[0006] On the basis of the above technical solutions, the application can also be improved as follows.
[0007] Optionally, in step S1, the industrial edge network is abstracted into an intelligent industrial network model composed of a plurality of heterogeneous edge nodes and links, and based on the intelligent industrial network model, the industrial application request is modeled as a request chain composed of a plurality of micro-services with data dependency relationship, comprising: S101, constructing an intelligent industrial network model based on a modular micro-service architecture according to the network configuration of the industrial edge network and the communication relationship of the servers, and defining the intelligent industrial network model as an undirected graph model ; Among them, is a set of edge nodes in the industrial edge network, ; Each edge node of the intelligent industrial network model contains an industrial switch and a group of heterogeneous edge servers, and each group of servers contains different numbers of cores , is a set of links connecting two servers , each physical link corresponds to a pair of connected server nodes , represents the maximum bandwidth capacity between two connected servers , represents the transmission delay between two connected servers; S102, defining that the industrial network service in the intelligent industrial network model is composed of a plurality of industrial micro-services with data dependency relationship, where is a set of all industrial micro-services; S103, according to the dynamically changing industrial application request, defining the related traffic of the request chain at moment as a request flow with Poisson distribution of arrival rate , For a collection of request streams, Representative request chain microservices Sequential logical sets, represent Request stream at any time Actual arrival rate , represent Request chain at any time The actual performance requirements, among which represent Request chain at any time Response priority represent Request chain at any time Response tolerance latency Then it means Request chain at any time The transmission bandwidth requirements.
[0008] Optionally, in step S1, the microservice instance deployment scheme and request routing scheme in the computation request chain include: S104, Obtain the microservice instance deployment scheme configured under the current industrial application request chain model. With request routing scheme ; in, The microservice instance deployment scheme of the time is described as follows: , represent The collection of all microservice instances in the current industrial application request chain model. represent The set of edge node resources occupied by all microservice instances in the current industrial application request chain model; The request routing scheme at any given time is described as follows: ,in, Defined as The set of routing paths for all request flows at any given time. Defined as The set of transition probabilities for all request flows at a given time.
[0009] Optionally, step S2 includes: S201, according to the time slots arriving in sequence and The request stream data is compared with the changes in the type of request stream and the arrival rate under the dual-timeslot scenario; S202, based on the calculation results of S201, according to The multivariate performance analysis model of the queue network calculates the dwell time of each microservice instance. Use the binary search algorithm to determine the satisfying Minimum number of cores for constraints ,in, for t The request chain that ensures core shrinkage does not cause performance degradation at any given time. The response latency threshold; S203, based on minimum core count For microservice instances whose single-node resources meet the scaling requirements, the deployment of that microservice instance on the current node will be expanded; for microservice instances whose single-node scaling is insufficient, they will be recorded in the migration set. .
[0010] Optionally, step S201 specifically includes: make The request stream set of the time slot is ,when Request stream of time slots Upon arrival, it is categorized according to the type of request. The existing request stream set in the time slot as well as New types of request streams arriving in time slots ; against The existing set of request streams at any given time ,consider Request flow arrival rate at any given time Changes to deployed microservice instances Load changes at the location, combined with The probability of route transition at time t and Request arrival rate at specific times Calculate the temporary request arrival rate at each instance. ; Based on the calculated temporary request arrival rate and Total request arrival rate at any given time Each microservice instance is divided into a set of load-reducing instances and a set of load-increasing instances.
[0011] Optionally, step S203 specifically includes: For the load reduction instance set, based on the minimum number of cores Release redundant cores; For the load-increasing instance set, based on the minimum number of cores Determine the remaining number of cores on the node where the microservice instance resides. Whether to meet resource constraints: if the remaining resources are sufficient, expansion is carried out, if the resource constraints are not met, the microservice instance is combined with the minimum core number Record to the set of instances to be migrated .
[0012] Optionally, step S3 comprises: S301, based on the preliminary dynamic scaling adjustment result, determining the deployment scheme of the new type of request flow based on the algorithm, and synchronizing to the set of instances to be migrated FFD ; ; S302, using a migration cost function to calculate the service interruption cost, pull deployment cost and resource occupation difference cost of each microservice instance in the set of instances to be migrated to the service of other nodes that meet the deployment constraints, to obtain a set of migration costs ; ; S303, based on a mixed integer nonlinear programming solver, determining the optimal migration expansion scheme of the microservice instances to be migrated in the set of instances to be migrated among the target nodes according to the migration costs, to update the microservice deployment scheme and the request routing scheme . .
[0013] Optionally, in step S302, the migration expansion algorithm is also used to construct a migration cost function based on the service interruption cost, the pull deployment cost and the resource occupation difference cost, and the migration cost function is expressed as:
[0014] wherein, is the migration cost, is the service interruption cost, is the service interruption cost weight, is the pull deployment cost of the current migration node, is the pull deployment cost weight of the current migration node, is the resource occupation difference cost, is the resource occupation difference cost weight; defines the microservice instance migrating from the source edge node to the target edge node , the interruption cost generated during the migration is , the duration of service interruption is represented as , and the service interruption cost at time is represented as:
[0015] wherein, the binary variable the meaning of all microservice instances at time whether to migrate to the target edge node , , the microservice instance deployed at the target edge node at time , is the set of all microservice instances in the system at time , the set of all microservice instances in the system at time ; the set of all microservice instances in the system at time ; the cost of pulling microservices , represents the pulling and deployment time of microservice , the deployment cost of the new instance at the target edge node when the microservice instance migrates is represented as:
[0016] the complete migration node pulling and deployment cost at time is represented as:
[0017] define the resource expenditure difference caused by microservice migration at time , including the instance communication expenditure difference and the instance resource occupation expenditure difference, represented as:
[0018] wherein, is the instance communication expenditure difference, is the instance communication expenditure difference weight, is the instance resource occupation expenditure difference, is the instance resource occupation expenditure difference weight; the instance communication expenditure difference and the instance resource occupation expenditure difference are respectively represented as:
[0019] .
[0020] wherein, is the residual bandwidth capacity between the two connected servers t at time , for Two connected servers at any time The remaining bandwidth capacity between for The source edge node where the microservice instance is located The number of cores for The source edge node where the microservice instance is located The number of core components.
[0021] Optionally, step S303 includes: Based on a mixed-integer nonlinear programming solver, the set to be migrated is determined according to the migration cost. The optimal migration and expansion scheme for microservice instances to be migrated between the source edge node and the target edge node is formalized as follows: Optimization objective and constraints:
[0022]
[0023] in, Indicates that solving makes When the minimum value is reached ( The value, Source edge node n Microservice Examples Core number, Source edge node n Accessing microservice instances Request delivery rate For target edge nodes Microservice Examples Core number, For target edge nodes Accessing microservice instances Request delivery rate For the source edge node n Microservice Examples The core number is and source edge nodes n Accessing microservice instances The request delivery rate Microservice Instance Processing latency, To the target edge node Microservice Examples The core number is and target edge nodes Accessing microservice instances The request delivery rate Microservice Instance Processing latency, For the microservice instance obtained by computation Maximum tolerable latency, for Time source edge node n Accessing microservice instances Request delivery rate The source edge node where the microservice instance resides n The remaining number of cores, For target edge nodes The remaining number of cores; Based on various constraints, and with the objective of minimizing migration cost, a mixed-integer nonlinear programming solver is invoked. Gurobi Solving the optimization objective yields an approximate optimal solution; Update based on the approximate optimal solution Moment's microservice deployment solution and request routing scheme .
[0024] According to a second aspect of the present invention, an industrial edge network microservice optimization system based on dynamic orchestration and migration expansion is provided, comprising: The pre-arrangement module is used to abstract the industrial edge network into an intelligent industrial network model composed of multiple heterogeneous edge nodes and links, and based on the intelligent industrial network model, to model industrial application requests as a request chain composed of multiple microservices with data dependencies in sequence, and to calculate the deployment scheme of microservice instances and the request routing scheme in the request chain. The core dynamic adjustment module is used to statistically analyze time-varying request streams in real time and utilize based on... m / m / c The minimum number of cores that meet latency constraints is analyzed in the multivariate performance analysis model and binary search algorithm analysis results of queue networks, and the core resources of deployed microservice instances are dynamically scaled and adjusted based on the analysis results. The orchestration optimization module is used to transform the complex multi-node migration decision problem into a mixed-integer nonlinear programming problem based on the initial dynamic scaling adjustment results and migration costs, and solve it. Based on the solution results, it realizes the optimal collaborative deployment of microservice instances and request routing optimization among edge nodes.
[0025] According to a third aspect of the present invention, an electronic device is provided, including a memory and a processor, wherein the processor is configured to implement the steps of the above-described industrial edge network microservice optimization method based on dynamic orchestration and migration extension when executing a computer management program stored in the memory.
[0026] According to a fourth aspect of the present application, a computer readable storage medium is provided, which stores a computer management program, and the computer management program is executed by a processor to implement the steps of the method for optimizing microservices of an industrial edge network based on dynamic scheduling and migration expansion.
[0027] The present application provides a method, system, electronic device and storage medium for optimizing microservices of an industrial edge network based on dynamic scheduling and migration expansion. By using the microservice collaborative optimization based on dynamic scheduling and migration expansion, the response time requirement of the system in the whole period is considered, the end-to-end request delay is reduced, the additional resource waste and energy cost caused by frequent migration are significantly reduced, the service continuity and overall energy efficiency of the industrial edge network system are improved, and the request success rate is maximized. BRIEF DESCRIPTION OF DRAWINGS
[0028] Figure 1 A flowchart of the method for optimizing microservices of an industrial edge network based on dynamic scheduling and migration expansion is provided. Figure 2 An intelligent industrial network model structure diagram is provided for an embodiment. Figure 3 A flowchart of dynamically adjusting the core resources of the deployed microservice instances is provided for an embodiment. Figure 4 A flowchart of optimally deploying and routing the microservice instances between the edge nodes by migration expansion is provided for an embodiment. Figure 5 A block diagram of the system for optimizing microservices of an industrial edge network based on dynamic scheduling and migration expansion is provided. Figure 6 A hardware structure diagram of a possible electronic device is provided. Figure 7 A hardware structure diagram of a possible computer readable storage medium is provided. DETAILED DESCRIPTION
[0029] The specific embodiments of the present application will be further described in detail below with reference to the accompanying drawings and embodiments. The following embodiments are used to illustrate the present application, but not to limit the scope of the present application.
[0030] Figure 1 A flowchart of the method for optimizing microservices of an industrial edge network based on dynamic scheduling and migration expansion is provided, as shown in Figure 1 The method includes steps S1-S3. S1, in the industrial Internet of Things and intelligent manufacturing scenarios, an industrial edge network is abstracted into an intelligent industrial network model composed of multiple heterogeneous edge nodes and links, an industrial application request is modeled into a request chain composed of multiple microservices sequentially combined based on the intelligent industrial network model, and a microservice instance deployment scheme and a request routing scheme in the request chain are calculated; S2, real-time statistics of time-varying request flow, utilization of a multi-element performance analysis model based on a queue network and a binary search algorithm to analyze the minimum core quantity meeting a delay constraint in the statistical result, and dynamic scaling adjustment of core resources of the deployed microservice instance based on the analysis result; m / m / c S3, according to the preliminary dynamic scaling adjustment result and migration cost, a complex multi-node migration decision problem is converted into a mixed integer nonlinear programming (MINLP) solving problem and solved, and optimal cooperative deployment and request routing optimization of the microservice instance between edge nodes are realized according to the solving result.
[0031] It can be understood that, based on the defects in the background art, the embodiments of the present application propose an industrial edge network microservice optimization method based on dynamic arrangement and migration expansion. In the industrial Internet of Things and intelligent manufacturing scenarios, the method adopts a microservice cooperative optimization mode based on dynamic arrangement and migration expansion, takes into account the response delay requirement of the system in the whole period, reduces the end-to-end request delay, not only significantly reduces the additional resource waste and energy consumption cost caused by frequent migration, improves the service continuity and overall energy efficiency of the industrial edge network system, but also maximizes the request success rate.
[0032] In a possible embodiment, please refer to Figure 2 , in step S1, in the industrial Internet of Things and intelligent manufacturing scenarios, an industrial edge network is abstracted into an intelligent industrial network model composed of multiple heterogeneous edge nodes and links, an industrial application request is modeled into a request chain composed of multiple microservices sequentially combined based on the intelligent industrial network model, and the specific steps include sub-steps S101-S103: S101, according to the network configuration of the industrial edge network and the communication relationship of the server, an intelligent industrial network model based on a modular microservice architecture is constructed, the intelligent industrial network model is defined as an undirected graph model ; wherein, is a set of edge nodes in the industrial edge network, ; for example Figure 2 the edge node , the edge node , the edge node , and the edge node .
[0033] Each edge node in the intelligent industrial network model comprises an industrial switch and a set of heterogeneous edge servers, with each set of servers containing a different number of cores. . To connect two servers A collection of links, each physical link A pair of corresponding connected server nodes Due to the resource constraints of edge networks, considering the bandwidth between adjacent nodes, Indicates two connected servers The maximum bandwidth capacity between links must be less than the total bandwidth resources occupied on the link. This indicates the transmission latency between two connected servers; S102, In a smart industrial environment based on a modular microservice architecture, the industrial network service in the smart industrial network model is defined as consisting of multiple industrial microservices with data dependencies. Composed of sequential combinations, ,in For a collection of all industrial microservices, such as Figure 2 Microservices shown Microservices Edge nodes Initiated industrial application request chain Microservices microservices microservices microservices Composed in sequence, edge nodes Initiated industrial application request chain Microservices microservices microservices It is composed of elements arranged in sequence.
[0034] S103, based on dynamically changing industrial application requests, will Request chain at any time Relevant traffic is defined as request flow whose arrival rate follows a Poisson distribution. , For a collection of request streams; Representative request chain microservices Sequential logical sets, represent Request stream at any time Actual arrival rate , represent Request chain at any time actual performance requirements, wherein represents the response priority of the request chain at the moment, represents the response tolerance delay of the request chain at the moment, represents the transmission bandwidth requirement of the request chain at the moment.
[0035] In one possible implementation manner, in step S1, the microservice instance deployment scheme and the request routing scheme in the request chain are calculated, including: S104, obtaining a microservice instance deployment scheme configured under a current industrial application request chain model and a request routing scheme .
[0036] In order to efficiently process complex and diverse industrial application requests in an industrial edge network, the arrangement of each microservice instance and the allocation of request flow in the entire physical network need to be considered. In the whole process of dynamic arrangement, the microservice is instantiated and deployed in an edge node , occupies a certain number of edge node resources , provides services externally, and due to the dynamic changes of service requirements and network load, the number of occupied resources or the deployment node of the instance is increased or decreased between different time slots. Therefore, the microservice instance deployment scheme at the moment is expressed as , represents the set of all microservice instances in the industrial application request chain model at the moment, represents the set of all microservice instances occupying edge node resources in the industrial application request chain model at the moment; When the request flow enters the industrial edge network, it is routed to the node where the microservice instance is deployed in sequence according to the microservice in the request chain for request flow processing, until the last microservice instance is processed, and the request flow processing is considered to be completed. In this process, in order to cope with the uneven distribution of resources and the dynamic changes of load in the network, the request flow can be dynamically allocated to different instances of the same microservice for processing according to the shunting strategy, so as to dynamically adapt to the computing power and resource state of different nodes. In order to more clearly describe this process, it is defined that is the request flow is transferred from a microservice instance to another microservice instance the probability of the request flow to be transferred to different microservice instances. Meanwhile, due to the forwarding route involved, the complete request flow processing procedure can contain multiple routing paths. Define as the routing path set of the request flow at time , where is the routing path of the specific node, and define binary variable to represent whether to stay at the edge node . From the above, the request flow routing scheme at time is expressed as , where is defined as the routing path set of all request flows at time , and is defined as the transfer probability set of all request flows at time .
[0037] In a possible implementation manner, as shown in the flowchart of Figure 3 , step S2 includes sub-steps S201-S203: S201, according to the request flow data of the time slots that arrive in sequence and , compare the type of the request flow and the change amount of the arrival rate in the double time slot case.
[0038] More specifically, sub-step S201 includes: When the time slot changes, the requests received from the industrial application by the edge cloud service cluster of the current intelligent factory also change accordingly. Let the request flow set of the time slot be , when the request flow of the time slot arrives, according to the request type, divide it into the request flow set of the time slot that already exists and the new type request flow set that arrives at the time slot . .
[0039] Among them, the request flow set of the time slot that already exists indicates that the corresponding microservice instance has deployed these request flows on the edge server, and in the time slot , only the change of the arrival rate needs to be considered. Correspondingly, the new type request flow that arrives at the time slot is The constantly increasing request flow types necessitate the deployment or migration of new microservice instances to meet the demands of new microservice instances and new routing requirements. To further reduce overall system overhead, a core scaling strategy with lower adjustment costs is prioritized, enabling more timely responses to changes in request load.
[0040] against The existing set of request streams at any given time First consideration Request flow arrival rate at any given time Changes to deployed microservice instances Load changes at the location, combined with The probability of route transition at time t and Request arrival rate at specific times Calculate the temporary request arrival rate at each instance. This provides the foundation for core control, thereby ensuring that microservice instances can flexibly respond to the time-varying characteristics of request traffic; Based on the calculated temporary request arrival rate and Total request arrival rate at any given time Each microservice instance is divided into a set of unloaded instances and a set of load-increasing instances to facilitate the shrinking and expansion of the core usage of microservice instances in the future.
[0041] S202, based on the calculation results of S201, according to The multivariate performance analysis model of the queue network calculates the dwell time of each microservice instance. The binary search multi-queue algorithm is used to determine the satisfying condition. Minimum number of cores for constraints ,in, for t The request chain that ensures core shrinkage does not cause performance degradation at any given time. The response latency threshold, i.e., the specified response time; for example, for edge nodes. n microservice instances It is necessary to determine whether the stay duration is met. Minimum number of cores , This is the response latency threshold for this microservice instance. Calculate the minimum number of cores. This ensures that core contraction saves costs while maintaining service quality, preventing the overall system performance from degrading.
[0042] S203, based on minimum core count For microservice instances whose single-node resources meet the scaling requirements, the deployment of that microservice instance on the current node will be expanded; for microservice instances whose single-node scaling is insufficient, they will be recorded in the migration set. .
[0043] In sub-step S203, load release and core expansion are performed on microservice instances that need to participate in scaling to meet service quality requirements.
[0044] In practice, to reduce resource waste and provide more free cores for overloaded instances, the algorithm prioritizes releasing cores from instances that are de-loaded. For the set of de-loaded instances, the algorithm determines which instances meet the required latency for their dwell time. Less than the specified response time Minimum number of cores for constraints By leveraging the scaling deployment mechanism of microservice instances, the load on edge nodes where microservice instances are deployed is reduced at a lower cost, freeing up redundant cores. After the redundant cores are released, core expansion of the load-increasing instances is then performed. During core expansion, for the set of load-increasing instances, binary search is also attempted to find instances with sufficient latency. Less than the specified response time Minimum number of cores for constraints And based on the minimum number of cores Determine the remaining number of cores on the node where the microservice instance resides. Does the microservice instance meet resource constraints? If there are sufficient remaining resources, expand the service; otherwise, merge the microservice instance with the minimum number of cores. Record to the collection of instances to be migrated .
[0045] It is understandable that in step S2, the microservice instance is completed. The node occupies the core Even after scaling adjustments, some instances (such as collections to be migrated) will still remain. The individual microservice instances in the network cannot meet the resource expansion requirements on a single edge node. The constant request load, coupled with the fact that existing microservice orchestration solutions cannot fully respond to it. New type of request stream arriving at the time Therefore, step S3 adopts a migration cost-based expansion strategy to transfer microservice instances between nodes.
[0046] In one possible embodiment, please refer to Figure 4 The process, step S3, includes sub-steps S301~S303: S301, based on the preliminary dynamic scaling adjustment results, based on FFD Algorithm determines new types of request streams The deployment plan was then synchronized to the set of instances to be migrated. .
[0047] Specifically, in order to effectively respond New type of request stream arriving at the time The first step is to implement a microservice orchestration scheme after core scaling has been completed. Building upon this foundation, additional microservice instances need to be deployed to support new types of request flows, utilizing industrial-grade... FFD The algorithm determines its initial routing scheme, and this initial solution will be recorded in the migration instance set. This facilitates subsequent steps in leveraging migration expansion to further optimize migration overhead and reduce migration costs.
[0048] S302, Determine the set of migration instances The migration cost of microservice instances to be migrated between target edge nodes is specifically calculated using a migration cost function to determine the migration cost of the set to be migrated. The service interruption cost, deployment pull cost, and resource consumption difference cost of migrating each microservice instance to other nodes that meet deployment constraints are used to obtain the migration cost set. .
[0049] It is understandable that migration costs need to be considered when migrating microservice instances. These migration costs include three components: the service interruption cost of migrating each microservice instance to other nodes that meet deployment constraints, the cost of pulling and deploying, and the cost of resource consumption differences.
[0050] First, a migration cost function needs to be constructed using the migration scaling algorithm based on service interruption cost, pull deployment cost, and resource consumption difference cost. The migration cost function is expressed as follows:
[0051] in, For migration costs, For service interruption costs, Weighting of service interruption costs The current deployment cost for migration nodes, To retrieve deployment cost weights for the current migration nodes, For the cost of the difference in resource usage, This is the weight of the cost difference in resource usage.
[0052] When migrating microservice instances, the relevant runtime data of the microservice instances needs to be transferred from the source edge node via the edge network. Synchronize to target edge node and at the target edge node The upper re-deployment starts. During this period, the microservice instance cannot provide services externally, causing service interruption. Therefore, frequent microservice instance migration affects the continuity of the service. Define the microservice instance migrates from the source edge node to the target edge node During this period, the interruption cost is , indicating the duration of service interruption, then the service interruption cost at time is expressed as:
[0053] where the binary variable represents whether the microservice instance migrates to the target edge node at time , , is the microservice instance deployed on the target edge node , is the set of all microservice instances in the system at time is the set of all microservice instances in the system at time .
[0054] When the microservice instance migrates, if there is no same microservice deployed on the target edge node , the microservice needs to be pulled from the cloud and then deployed. If there is already a same microservice deployed, there is no corresponding pulling cost. Define the cost of pulling the microservice as , indicating the pulling and deployment time of the microservice , then the new instance deployment cost of the target edge node when the microservice instance migrates is expressed as:
[0055] Therefore, the complete migration node pulling and deployment cost at time is expressed as:
[0056] Since the microservice application is characterized by a chain structure, when the microservice instance migrates between edge nodes, it will change the communication overhead between microservice instances. At the same time, due to the influence of request performance constraints, it will also change the amount of resources occupied by upstream and downstream microservice instances, thereby affecting the cost of microservice instance migration. Define as The resource overhead difference caused by microservice migration at the moment, including the instance communication overhead difference and the instance resource occupation overhead difference, is represented as:
[0057] wherein, is the instance communication overhead difference, is the instance communication overhead difference weight, is the instance resource occupation overhead difference, is the instance resource occupation overhead difference weight; The instance communication overhead difference and the instance resource occupation overhead difference are respectively represented as:
[0058] .
[0059] wherein, is the residual bandwidth capacity between the two connected servers at the moment t is the residual bandwidth capacity between the two connected servers at the moment is the core number of the source edge node where the microservice instance is located at the moment is the core number of the source edge node where the microservice instance is located at the moment -1 is the core number of the source edge node where the microservice instance is located at the moment -1 is the core number of the source edge node where the microservice instance is located at the moment t n t n
[0060] Traverse the microservice instances in the migration instance set , calculate the migration cost and record it in the migration cost set . Subsequently, based on the principle of minimum migration cost, the migration expansion scheme of each instance is evaluated. Since the migration process will not only generate the deployment cost of node resource occupation and the service interruption cost of related industrial application requests being executed, but also further consider the instance routing delay expectation difference before and after adjustment to correct the performance loss caused by migration.
[0061] S303, based on the mixed integer nonlinear programming solver Gurobi , the optimal migration expansion scheme of the microservice instance to be migrated among the target nodes is determined according to the migration cost, specifically: based on the mixed integer nonlinear programming solver, the optimal migration expansion scheme of the microservice instance to be migrated in the migration instance set among the target nodes is determined according to the migration cost, to update the microservice deployment scheme and the request routing scheme .
[0062] Understandably, in In a queuing model, scaling up a single instance results in performance degradation. Given instance processing latency constraints, to compensate for this, edge nodes need more cores to offset the performance loss, while simultaneously distributing the load from arriving requests evenly to achieve maximum processing efficiency. Because... The nonlinear characteristics of queuing systems require further consideration of the nonlinear constraints of queuing delay calculation and core resource allocation. Accordingly, this step models the complex multi-node migration decision problem as a typical mixed-integer nonlinear programming (MINLP) problem to achieve optimal collaborative deployment and request routing optimization of microservice instances among edge nodes.
[0063] Therefore, in order to minimize the additional migration cost caused by the split expansion, in sub-step S303, based on the mixed-integer nonlinear programming solver, the set to be migrated is divided according to the migration cost. The optimal migration and expansion scheme for microservice instances to be migrated between the source edge node and the target edge node is formalized as follows: Optimization objective and constraints:
[0064]
[0065] in, Indicates that solving makes When the minimum value is reached ( The value, Source edge node n Microservice Examples Core number, Source edge node n Accessing microservice instances Request delivery rate For target edge nodes Microservice Examples Core number, For target edge nodes Accessing microservice instances Request delivery rate For the source edge node n Microservice Examples The core number is and source edge nodes n Accessing microservice instances The request delivery rate Microservice Instance Processing latency, To the target edge node Microservice Examples The core number is and target edge nodes Accessing microservice instances The request delivery rate Microservice Instance Processing latency, For the microservice instance obtained by computation Maximum tolerable latency, for Time source edge node n Accessing microservice instances Request delivery rate The source edge node where the microservice instance resides n The remaining number of cores, For target edge nodes The remaining number of cores.
[0066] Based on the above constraints, and ensuring that the deployment cost of each microservice is below a preset threshold, a migration cost function is constructed that includes service interruption cost, pull deployment cost, and resource consumption difference cost. These costs are then combined in a weighted summation, and the goal is to minimize this weighted cost by calling its standard solver. Gurobi The interface solves the mixed-integer nonlinear programming (MINLP) problem, outputting an approximate optimal solution. This optimal solution corresponds to the migration scheme that minimizes the total cost of microservice migration while satisfying the low deployment cost constraint. It further clarifies the deployment and migration decisions for each microservice instance among candidate nodes in the edge network, and updates the system based on this optimal solution. Moment's microservice deployment solution and request routing scheme .
[0067] Figure 5 A structural diagram of an industrial edge network microservice optimization system based on dynamic orchestration and migration expansion is provided for an embodiment of the present invention, as shown below. Figure 5 As shown, an industrial edge network microservice optimization system based on dynamic orchestration and migration expansion includes a pre-orchestration module, a core dynamic adjustment module, and an orchestration optimization module, wherein: The pre-arrangement module is used to abstract the industrial edge network into an intelligent industrial network model composed of multiple heterogeneous edge nodes and links, and based on the intelligent industrial network model, to model industrial application requests as a request chain composed of multiple microservices with data dependencies in sequence, and to calculate the deployment scheme of microservice instances and the request routing scheme in the request chain. The core dynamic adjustment module is used to statistically analyze time-varying request streams in real time and utilize based on...m / m / c the minimum core quantity satisfying the delay constraint in the statistical result is analyzed by using a multi-element performance analysis model of a queue network and a binary search algorithm, and the core resources of the deployed microservice instances are dynamically scaled based on the analysis result; The orchestration optimization module is configured to convert a complex multi-node migration decision problem into a mixed integer nonlinear programming solving problem and solve the problem according to the preliminary dynamic scaling result and the migration cost, and realize optimal cooperative deployment and request routing optimization of the microservice instances among the edge nodes according to the solving result.
[0068] It can be understood that the industrial edge network microservice optimization system based on dynamic orchestration and migration expansion provided by the present application corresponds to the industrial edge network microservice optimization method based on dynamic orchestration and migration expansion provided by the foregoing embodiments, and the related technical features of the industrial edge network microservice optimization system based on dynamic orchestration and migration expansion can refer to the related technical features of the industrial edge network microservice optimization method based on dynamic orchestration and migration expansion, which will not be repeated here.
[0069] Please refer to Figure 6 , Figure 6 The embodiment of the electronic device provided by the present application is shown in the figure. As shown in Figure 6 The present application provides an electronic device 600, which includes a memory 610, a processor 620, and a computer program 611 stored in the memory 610 and executable on the processor 620. When the processor 620 executes the computer program 611, the following steps are implemented: S1, abstracting the industrial edge network into an intelligent industrial network model composed of multiple heterogeneous edge nodes and links, modeling the industrial application request as a request chain composed of multiple microservices with data dependency based on the intelligent industrial network model, and calculating the microservice instance deployment scheme and request routing scheme in the request chain; S2, real-time statistics of time-varying request flow, using a multi-element performance analysis model of a queue network and a binary search algorithm to analyze the minimum core quantity satisfying the delay constraint in the statistical result, and dynamically scaling the core resources of the deployed microservice instances based on the analysis result; m / m / c S3, according to the preliminary dynamic scaling result and the migration cost, converting a complex multi-node migration decision problem into a mixed integer nonlinear programming solving problem and solving the problem, and realizing optimal cooperative deployment and request routing optimization of the microservice instances among the edge nodes according to the solving result. Please refer to
[0070] , Figure 7 , Figure 7 The embodiment of the computer readable storage medium provided by the present application is shown in the figure. As shown in Figure 7As shown, the embodiment provides a computer readable storage medium 700, which stores a computer program 711, and the computer program 711 is executed by a processor to implement the following steps: S1, abstracting the industrial edge network into an intelligent industrial network model composed of a plurality of heterogeneous edge nodes and links, modeling an industrial application request into a request chain composed of a plurality of microservices with data dependency relationship based on the intelligent industrial network model, and calculating a microservice instance deployment scheme and a request routing scheme in the request chain; S2, real-time statistics of time-varying request flow, using a multi-element performance analysis model based on a queue network and a binary search algorithm to analyze the minimum core number that meets the delay constraint in the statistical result, and based on the analysis result, dynamically adjusting the core resources of the deployed microservice instance; m / m / c S3, according to the preliminary dynamic scaling adjustment result and the migration cost, converting the complex multi-node migration decision problem into a mixed integer nonlinear programming solving problem and solving, and according to the solving result, realizing the optimal cooperative deployment and request routing optimization of the microservice instance between the edge nodes.
[0071] The industrial edge network microservice optimization method, system, electronic device and storage medium provided by the embodiment of the application can realize the microservice cooperative optimization based on dynamic arrangement and migration expansion, take into account the response time delay requirement of the system in the whole period, reduce the end-to-end request delay, not only significantly reduce the additional resource waste and energy consumption cost caused by frequent migration, improve the service continuity and overall energy efficiency of the industrial edge network system, but also maximize the guarantee of request success rate.
[0072] It should be noted that in the above embodiments, the description of each embodiment has its own emphasis, and the parts not described in detail in a certain embodiment can be referred to the related description of other embodiments.
[0073] Those skilled in the art should understand that the embodiments of the application can be provided as a method, a system, or a computer program product. Therefore, the application can be in the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the application can be in 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.
[0074] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart block or blocks. Figure 1 one or more flowcharts and / or blocks Figure 1 means for functionally implementing the steps listed in the flowchart
[0075] These computer program instructions can also be stored in a computer- readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instructions which implement the function specified in the flowchart block or blocks. Figure 1 one or more flowcharts and / or blocks Figure 1 means for functionally implementing the steps listed in the flowchart
[0076] The computer program instructions can also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart block or blocks. Figure 1 one or more flowcharts and / or blocks Figure 1 means for functionally implementing the steps listed in the flowchart
[0077] While the preferred embodiments of the application have been described, additional variations and modifications can be employed by those skilled in the art. Therefore, the appended claims are intended to cover all such variations and modifications as falling within the scope of the application.
[0078] Obviously, numerous modifications and variations of the present application are possible in light of the above teachings. It is therefore to be understood that within the scope of the appended claims and their equivalents, the application can be practiced otherwise than as specifically described.
Claims
1. A method for optimizing industrial edge network microservices based on dynamic orchestration and migration extension, characterized in that, Comprise: S1, abstracting the industrial edge network into an intelligent industrial network model composed of a plurality of heterogeneous edge nodes and links, modeling the industrial application request into a request chain composed of a plurality of microservices with data dependency relationship based on the intelligent industrial network model, and calculating the microservice instance deployment scheme and request routing scheme in the request chain; S2, real-time statistics time-varying request flow, using based on m / m / c The multi-element performance analysis model of the queue network and the binary search algorithm analyze the minimum core quantity meeting the delay constraint in the statistical result, and based on the analysis result, the core resources of the deployed micro-service instances are dynamically adjusted. S3, according to the preliminary dynamic scaling adjustment result and the migration cost, converting the complex multi-node migration decision problem into a mixed integer nonlinear programming solving problem and solving, and realizing the optimal cooperative deployment of microservice instances between edge nodes and request routing optimization according to the solving result.
2. The industrial edge network microservice optimization method based on dynamic arrangement and migration expansion according to claim 1, characterized in that, In step S1, the industrial edge network is abstracted into an intelligent industrial network model composed of a plurality of heterogeneous edge nodes and links, and the industrial application request is modeled into a request chain composed of a plurality of microservices with data dependency relationship based on the intelligent industrial network model, comprising: In S101, an intelligent industrial network model based on a modular micro-service architecture is constructed according to a network configuration of the industrial edge network and a communication relationship of the server, and the intelligent industrial network model is defined as an undirected graph model. ; wherein is a set of edge nodes in an industrial edge network ; Each edge node in the intelligent industrial network model comprises an industrial switch and a set of heterogeneous edge servers, with each set of servers containing a different number of cores. , To connect two servers A collection of links, each physical link A pair of corresponding connected server nodes , Indicates two connected servers Maximum bandwidth capacity between This indicates the transmission latency between two connected servers; S102, define that the industrial network service in the intelligent industrial network model is sequentially combined by a plurality of industrial microservices ms with data dependency relationship, wherein is a set of all industrial microservices; S103, according to the dynamically changing industrial application request, the request chain at the moment is defined as a request flow with a Poisson distribution of arrival rate , is a request flow set, represents the microservice of the request chain sequence logic set, represents the actual arrival rate of the request flow at the moment , represents the actual performance demand of the request chain at the moment represents the response priority of the request chain at the moment represents the response tolerance delay of the request chain at the moment represents the transmission bandwidth demand of the request chain at the moment.
3. The method of claim 2, wherein, In step S1, the calculation of the microservice instance deployment scheme and the request routing scheme in the request chain comprises: S104, acquire the micro-service instance deployment scheme configured under the current industrial application request chain model with the request routing scheme ; wherein, a microservice instance deployment scheme at a time point t is represented as , represents a set of all microservice instances in the industrial application request chain model at a time point t, represents a set of all microservice instances occupying edge node resources in the industrial application request chain model at a time point t; The request routing scheme at time t is denoted as where, is defined as is a set of routing paths for all request flows at time t, is defined as is a set of transition probabilities for all request flows at time t.
4. The industrial edge network microservice optimization method based on dynamic arrangement and migration expansion according to claim 3, characterized in that, Step S2 comprises: S201, according to the time slot of the order of arrival and request flow data, compared to the type of request flow and the change of arrival rate in the case of double time slot S202, based on the calculation results of S201, according to The multivariate performance analysis model of the queue network calculates the dwell time of each microservice instance. Use the binary search algorithm to determine the satisfying Minimum number of cores for constraints ,in, for The request chain that ensures core shrinkage does not cause performance degradation at any given time. The response latency threshold; S203, based on the minimum core number For the micro-service instance that satisfies the scaling condition, the deployment of the micro-service instance in the current node is expanded; for the micro-service instance that is insufficiently expanded in a single node, the micro-service instance is recorded to a to-be-migrated set .
5. The method of claim 4, wherein, Step S201 specifically comprises: Let the request flow set of the time slot be , when the request flow of the time slot arrives, it is divided into the request flow set of the time slot already existing and the new request flow set of the time slot arriving ; against The existing set of request streams at any given time ,consider Request flow arrival rate at any given time Changes to deployed microservice instances Load changes at the location, combined with The probability of route transition at time t and Request arrival rate at specific times Calculate the temporary request arrival rate at each instance. ; According to the calculated temporary request arrival rate With The total request arrival rate at the moment The microservice instances are divided into the load reduction instance set and the load increase instance set respectively.
6. The industrial edge network microservice optimization method based on dynamic arrangement and migration expansion according to claim 5, characterized in that, Step S203 specifically comprises: For the reduced set of instances, release the redundant cores according to the minimum core number . For the load-up instance set, according to the minimum core number Determine the remaining core number of the node where the microservice instance is located Whether the resource constraint is met: if the remaining resources are sufficient, the expansion is performed, and if the resource constraint is not met, the microservice instance and the minimum core number Record to the to-be-migrated instance set .
7. The industrial edge network microservice optimization method based on dynamic arrangement and migration expansion according to claim 6, characterized in that, Step S3 comprises: S301, on the basis of the preliminary dynamic scaling adjustment result, determine the deployment scheme of the new category request flow based on the algorithm, and synchronize to the to-be-migrated instance set. FFD ; S302, calculate the migration cost function for each micro-service instance in the to-be-migrated set , the service interruption cost, the pull deployment cost and the resource occupation difference cost of migrating each micro-service instance in the to-be-migrated set to other nodes satisfying the deployment constraint, to obtain a migration cost set ; S303, determining the to-be-migrated set according to the migration cost based on a mixed integer nonlinear programming solver The optimal migration expansion scheme of the to-be-migrated microservice instances among the target nodes is determined to update the microservice deployment scheme And a request routing scheme .
8. The industrial edge network microservice optimization method based on dynamic arrangement and migration expansion according to claim 7, characterized in that, In step S302, further comprising: constructing a migration cost function based on the service interruption cost, the pull deployment cost and the resource occupation difference cost by using the migration expansion algorithm, and the migration cost function is expressed as: wherein, is a migration cost, is a service interruption cost, is a service interruption cost weight, is a current migration node pulling deployment cost, is a current migration node pulling deployment cost weight, is a resource occupation difference cost, is a resource occupation difference cost weight; Defining microservice instances From source edge node Migrating to target edge node The interruption cost during , which represents the duration of service interruption, then The service interruption cost at time is represented as: wherein the binary variable has the meaning of whether the microservice instance is migrated to the target edge node at the time instant , is the microservice instance deployed at the target edge node at the time instant , is the set of all microservice instances in the system at the time instant is the set of all microservice instances in the system at the time instant Definition of pull microservice The cost of generation is , represents the pull of the microservice , and the deployment time, then the new instance deployment cost at the target edge node when the microservice instance migrates is represented as: complete migration node pull deployment cost at a time instant is represented as: Definitions For The resource overhead difference caused by microservice migration at the moment, including the instance communication overhead difference and the instance resource occupation overhead difference, is represented as: wherein, is an inter-instance communication overhead difference, is an inter-instance communication overhead difference weight, is an instance resource occupancy overhead difference, is an instance resource occupancy overhead difference weight; Example intercommunication overhead delta With instance resource occupancy overhead delta Respectively denoted as: wherein, is t the remaining bandwidth capacity between the two connected servers at the moment, is the remaining bandwidth capacity between the two connected servers at the moment -1, t is the remaining bandwidth capacity between the two connected servers at the moment -1, is t the number of cores of the source edge node where the microservice instance is located at the moment, n is the number of cores of the source edge node where the microservice instance is located at the moment -1, is n the number of cores of the source edge node where the microservice instance is located at the moment -1.
9. The industrial edge network microservice optimization method based on dynamic arrangement and migration expansion according to claim 7 or 8, characterized in that, Step S303 comprises: Based on the mixed integer nonlinear programming solver, according to the migration cost, the set to be migrated The optimal migration expansion scheme of the micro-service instances to be migrated between the source edge node and the target edge node is formalized as the following optimization objective and constraint conditions: in, Indicates that solving makes When the minimum value is reached ( The value, Source edge node n Microservice Examples Core number, Source edge node n Accessing microservice instances Request delivery rate For target edge nodes Microservice Examples Core number, For target edge nodes Accessing microservice instances Request delivery rate For the source edge node n Microservice Examples The core number is and source edge nodes n Accessing microservice instances The request delivery rate Microservice Instance Processing latency, To the target edge node Microservice Examples The core number is and target edge nodes Accessing microservice instances The request delivery rate Microservice Instance Processing latency, For the microservice instance obtained by computation Maximum tolerable latency, for Time source edge node n Accessing microservice instances Request delivery rate The source edge node where the microservice instance resides n The remaining number of cores, For target edge nodes The remaining number of cores; Based on each constraint condition, calling a mixed integer nonlinear programming solver to minimize the migration cost Gurobi Solving the optimization target to obtain an approximate optimal solution updating the approximate optimal solution according to the result of the comparison Microservice deployment scheme at the time And request routing scheme .
10. An industrial edge network microservice optimization system based on dynamic orchestration and migration extension, characterized in that, Comprise: The pre-arrangement module is used for abstracting the industrial edge network into an intelligent industrial network model composed of a plurality of heterogeneous edge nodes and links, modeling the industrial application request into a request chain composed of a plurality of microservices with data dependency relationship based on the intelligent industrial network model, and calculating the microservice instance deployment scheme and request routing scheme in the request chain; The core dynamic adjustment module is configured to statistically count time-varying request flows in real time, and utilize a multi-element performance analysis model based on a queue network and a binary search algorithm to analyze the minimum core quantity satisfying the delay constraint in the statistical result, and to perform dynamic scaling adjustment of the core resources of the deployed microservice instances based on the analysis result. m / m / c The queue network-based multi-element performance analysis model and the binary search algorithm analyze the minimum core quantity satisfying the delay constraint in the statistical result, and perform dynamic scaling adjustment of the core resources of the deployed microservice instances based on the analysis result. The arrangement optimization module is used for converting the complex multi-node migration decision problem into a mixed integer nonlinear programming solving problem and solving according to the preliminary dynamic scaling adjustment result and the migration cost, and realizing the optimal cooperative deployment of microservice instances between edge nodes and request routing optimization according to the solving result.
Citation Information
Patent Citations
Micro-service resource configuration method based on cloud data center
CN116627660A
Micro-service deployment method and system based on edge computing
CN117201319A
Micro-service deployment and request routing method and system based on edge network, and medium
CN117527590A
Dynamic micro-service migration and route redirection method and system based on topology awareness
CN119676150A
Micro-service scaling and request route updating method, system and equipment based on data awareness
CN119766864A
Cited By
Micro-service migration method, device and equipment and computer readable storage medium
CN121644675A