A computing resource discovery method and system based on a two-level programming model
Through the two-layer planning model and multi-objective particle swarm optimization algorithm, the problems of low resource discovery efficiency and high energy consumption in the cloud access network are solved, and the accuracy and efficiency of resource discovery are improved, and adapted to changing network environments are adapted.
Patent Information
- Application Number
- CN202411290707.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-14
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2044-09-14
AI Technical Summary
In a cloud access network environment, resource discovery faces challenges of changing node mobility and resource availability, especially in a multi-tenant environment, which makes it difficult to track resource status in real time, resulting in low resource discovery efficiency and high energy consumption.
The computing resource discovery method based on the two-layer planning model is adopted, and the proxy node and resource discovery mode are determined through the multi-objective particle swarm optimization algorithm, the network topology structure and resource management model are optimized, and the time cost and energy consumption of resource discovery are reduced.
It improves the accuracy and efficiency of resource discovery, reduces time cost and energy consumption, enhances the flexibility and effectiveness of network topology, and adapts to dynamically changing network environments.
Smart Images

Figure CN118827314B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to computing resource discovery technology, and in particular to a computing resource discovery method and system based on a double-layer programming model. Background Art
[0002] Cloud access network resources consist of communication facilities and necessary servers, and are usually provided by agents in specific domain networks. For cloud access network resources, perception and discovery are the prerequisites for allocating applications, and resource discovery often faces more complex problem scenarios. Mobile devices usually exhibit the characteristics of free movement, and server selection and configuration also have obvious variability, resulting in obvious dynamic changes in network topology.
[0003] The challenges faced by resource discovery include node mobility and continuous availability of resources. In wireless access environments, nodes are frequently disconnected and restored, making it difficult to track resource status in real time. In a multi-tenant environment, nodes may belong to different owners, and sudden fluctuations in workloads may cause rapid changes in available resources between different tenants, requiring timely monitoring of resource changes. Summary of the invention
[0004] The present invention proposes a computing resource discovery method based on a double-layer programming model.
[0005] The technical solution to achieve the purpose of the present invention is: a computing resource discovery method based on a two-level programming model, comprising:
[0006] Step 1: Determine a candidate set of proxy nodes from all nodes participating in computing resource discovery in the cloud access network system;
[0007] Step 2: Establish a two-layer planning model for cloud access network computing resource discovery;
[0008] Step 3: Use the multi-objective particle swarm optimization algorithm to solve the bi-level programming model and determine the agent nodes and resource discovery mode involved in resource discovery;
[0009] Step 4: According to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, select the proxy node and configure it;
[0010] Step 5: According to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, the resource discovery mode of each proxy node is selected, and the corresponding resource discovery mode is run to search for network resource information and transmit the resource information list to all nodes.
[0011] Preferably, the specific method for determining the candidate set of proxy nodes from all nodes participating in computing resource discovery in the cloud access network system is:
[0012] Step 1.1: Initialize all nodes participating in computing resource discovery from the cloud access network system, and record basic information of each node, including unique identification, physical location, computing capacity, and current load;
[0013] Step 1.2: By analyzing the network topology and node attributes, potential proxy nodes are screened out from all nodes and put into the proxy node candidate set.
[0014] Preferably, by analyzing the network topology and node attributes, potential proxy nodes are screened out from all nodes, and the specific method of putting them into the candidate set of proxy nodes is as follows:
[0015] Collect information about all nodes and links in the network, build a topological graph, and perform topological characteristic analysis. Filter nodes in turn according to node degree, path length, clustering coefficient, and betweenness centrality.
[0016] The comprehensive scores of the selected proxy nodes are calculated, and the proxy nodes with comprehensive scores greater than the set score threshold are added to the proxy node candidate set.
[0017] Preferably, the clustering coefficient The calculation formula is:
[0018]
[0019] in, Is a node The actual number of connections between neighbors, Is a node degree;
[0020] Betweenness centrality of a node The calculation formula is:
[0021]
[0022] in, It is a slave node To Node The total number of shortest paths, It passes through the node The number of shortest paths.
[0023] Preferably, the comprehensive score of the proxy node The calculation formula is:
[0024] ;
[0025] In the formula, For Node The stability score is , , Give the node a network score, specifically , The calculation score of the node is , , and is the weight coefficient of each score.
[0026] Preferably, the two-level planning model includes an upper-level planning model and a lower-level planning model, and the objective function and constraints of the upper-level planning model are specifically:
[0027] (1),
[0028] (2),
[0029] (3),
[0030] (4),
[0031] (5),
[0032] (6),
[0033] (7),
[0034] In the formula, is a time collection, which is a sequence of time points for the project within the time window. Indicates a point in time, , Indicates the total number of time points, represents the set of computing nodes in the cloud access network, Represents the set of proxy nodes in the cloud access network computing nodes, Represents the cloud access network computing node proxy node The configuration time required, Indicates the time required to establish a connection between the computing node and the proxy node of the cloud access network. is the decision variable, the decision variable A value of 1 indicates that for The time window A resource-adaptive node is selected and configured as a resource-adaptive node for expansion balancing. As a cloud access network computing node with a specified configuration; decision variables A value of 0 indicates a cloud access network computing node that has not been selected by any node. is the decision variable, the decision variable 1 means that for a certain time point Resource adaptation, node The resource scheduler runs in management mode, that is, active mode, and the decision variable 0 means passive mode. is the decision variable, the decision variable 1 indicates that the node is calculated at a certain time point Selected as a computing node for expansion resource adaptation; decision variables 0 means not selected;
[0035] The objective function and constraints of the lower-level planning model are specifically:
[0036] (8),
[0037] (9),
[0038] (10),
[0039] (11),
[0040] (12)
[0041] in, For the The node resource management requirements at a time point, the energy consumption of node i in the active mode to complete the resource scheduling process, For the node resource management requirements at the kth time point, the energy consumption of node i in the passive mode to complete the resource scheduling process is: Indicates the contribution of node i to the resource discovery information state when it chooses passive mode. The minimum total threshold of resource information status flags required by the cloud access network system in passive mode. The minimum total threshold of resource information status flags required by the cloud access network system in active mode.
[0042] The computing resource discovery method based on the two-level programming model is characterized in that for the The energy consumption of node i in active mode to complete the resource scheduling process is calculated as follows:
[0043]
[0044] in, is the duration of the detection cycle, is the energy consumption of each query request; It is the total number of times all nodes successfully detect new resources in a detection cycle.
[0045] For the node resource management requirements at the kth time point, the energy consumption of node i in the passive mode to complete the resource scheduling process is calculated as follows:
[0046]
[0047] in is the total number of nodes in the network participating in resource discovery; is the expected state of the node; is the energy consumption per received data packet.
[0048] Preferably, the improved multi-objective particle swarm optimization algorithm is used to solve the bi-level programming model, and the specific method for determining the proxy nodes involved in resource discovery and the resource discovery mode is as follows:
[0049] Step 31: Randomly initialize the particle group and the initial position of each particle and speed At the same time, it is randomly initialized to initialize the individual optimal position of each particle and the global optimal position ;
[0050] Step 32: Each solution of the two-level programming model includes power consumption and time cost, with power consumption as the horizontal axis and time cost as the vertical axis;
[0051] The dominance relationship between individuals is determined according to the Pareto dominance relationship, and the Euclidean distance from the corresponding coordinates of each solution to the Pareto frontier is calculated. The minimum value of the Euclidean distance is taken as the distance from the solution to the Pareto frontier and used as the fitness. The Pareto frontier consists of a group of non-dominated solutions, and each solution in the group is a non-dominated solution in the multi-objective optimization of the bi-level programming model.
[0052] Step 33: Update particle speed and position. The specific formula is:
[0053]
[0054]
[0055] In the formula Indicates In the iteration The speed of a particle, represents the inertia weight, It is In this iteration The speed of a particle, is the current iteration number, is the individual learning factor, controlling the particle to its optimal position The degree of mobility, is the social learning factor, controlling the particle to move to the global optimal position The degree of mobility, and It is a random number between 0 and 1 used to ensure the randomness and diversity of the algorithm. is the optimal position found by the jth particle in the historical iteration process, is the optimal position found by all particles in the historical iteration process, No. In the iteration The position of a particle;
[0056] Step 34: Update the optimal position of each particle according to the local fitness and the global optimal position before the disturbance ;
[0057] Individual optimal position update, if the particle position of the current iteration The fitness is better than the previous optimal position The fitness of the individual is updated for , the individual optimal position The best position before ;
[0058] The global optimal position is updated. If the particle position of the current iteration The fitness is better than the previous global optimal position The fitness of the global optimal position before the disturbance is updated for , update the global optimal position before disturbance is the previous global optimal position ;
[0059] Step 35: Update the global optimal position Make a small perturbation, the specific formula is:
[0060]
[0061] in, is the random disturbance, is the updated global optimal position;
[0062] Step 36: If the updated particle position reaches the maximum number of iterations or the convergence condition, stop the iteration and proceed to step 37, otherwise return to step 32;
[0063] Step 37: Remove the dominated solutions in the external archive, and based on the updated archive, continue to screen and retain the non-dominated solutions in the external archive, and update the archive.
[0064] Preferably, the dynamic adjustment formula of the inertia weight is:
[0065]
[0066] in, is the maximum value of the inertia weight, is the minimum value of the inertia weight, is the maximum number of iterations.
[0067] The present invention also proposes a computing resource discovery system based on a two-level programming model, comprising:
[0068] The proxy node determination module is used to determine a set of proxy node candidates from all nodes participating in computing resource discovery in the cloud access network system;
[0069] A two-layer planning model, wherein the two-layer planning model includes an upper-layer planning model and a lower-layer planning model, wherein the upper-layer planning model is used to perform targeted network topology design for the network state migration problem of cloud access network computing resources, and the lower-layer planning model is used to optimize the selection of timely node operation modes under the target drive of total energy consumption and the constraint of resource information state flags;
[0070] The bi-level programming model solving module is used to solve the bi-level programming model using a multi-objective particle swarm optimization algorithm to determine the proxy nodes involved in resource discovery and the resource discovery mode;
[0071] The proxy solution configuration module is used to select and configure proxy nodes based on the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm;
[0072] The resource discovery mode operation module is used to select the resource discovery mode of each proxy node according to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, and run the corresponding resource discovery mode to search for network resource information and transmit the resource information list to all nodes.
[0073] Compared with the prior art, the present invention has the following significant advantages:
[0074] The present invention improves the accuracy and efficiency of resource discovery, reduces the time cost of resource discovery and reduces energy consumption, increases the flexibility and effectiveness of network topology, and adapts to changing network environments;
[0075] The present invention optimizes the resource discovery process through a two-layer planning model. The upper-layer planning model determines a reasonable resource network structure and reduces the total time cost of resource discovery agent services. The lower-layer planning model explores effective cloud access network resource discovery modes and reduces total energy consumption.
[0076] The present invention ensures that the migration of the network topology structure of cloud access network computing resources is based on the optimal total time decision-making target, and improves the flexibility and effectiveness of the network topology. By selecting different computing resource discovery modes, efficient resource discovery is achieved under the premise of meeting energy consumption constraints. Based on the heuristic algorithm of multi-objective particle swarm optimization, the proposed two-level programming model is solved, and the optimal decision for resource discovery is obtained to optimize the energy consumption and time cost in the resource discovery process.
[0077] The present invention is described in further detail below in conjunction with the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0078] Figure 1 Schematic diagram of the two-level planning model.
[0079] Figure 2 Discovery flow chart for computing resources.
[0080] Figure 3 This is a schematic diagram of network topology migration. DETAILED DESCRIPTION
[0081] like Figures 1 to 3 As shown, a computing resource discovery method based on a two-level planning model includes:
[0082] Step 1: Determine a candidate set of proxy nodes from all nodes participating in computing resource discovery in the cloud access network system. The specific steps are as follows:
[0083] Step 1.1: During the initialization process of node selection, all nodes participating in computing resource discovery are initialized from the cloud access network system, including computing nodes and proxy nodes. The basic information of each node is recorded, including its unique identification, physical location, computing capacity, and current load.
[0084] Step 1.2: By analyzing the network topology and node attributes, potential proxy nodes are screened out from all nodes and put into the proxy node candidate set. Factors considered in the screening process include:
[0085] 1. Computing power of the node: Select nodes with computing power greater than the set threshold to ensure that the proxy node can work normally under high load conditions.
[0086] 2. Node stability: Prioritize nodes that have performed stably and have low failure rates in historical operations.
[0087] 3. Network connection quality of the node: Select nodes with good network connection quality to ensure efficient and stable communication during the resource discovery process.
[0088] Furthermore, by analyzing the network topology and node attributes, potential proxy nodes are screened out from all nodes. The specific method of putting them into the candidate set of proxy nodes is as follows:
[0089] Step 1.2.1: The purpose of network topology analysis is to understand the node distribution and connection status in order to select appropriate proxy nodes. The specific analysis steps include: topology data collection, topology map construction and topology characteristic analysis.
[0090] Specifically, topology data collection includes:
[0091] ① Node information collection, that is, collecting information of all nodes in the network, including node ID, geographic location, computing power, storage capacity, etc.;
[0092] ② Link information collection, that is, the connection information between nodes, including connection bandwidth, delay, packet loss rate, etc.
[0093] Topology map construction includes:
[0094] ①Node marking, that is, marking the location and attributes of all nodes in the topology map;
[0095] ② Edge marking, that is, marking the connections between all nodes in the topology graph, and noting the connection properties such as bandwidth and delay.
[0096] The topological characteristics analysis is mainly carried out from the aspects of node degree, path length, clustering coefficient and betweenness centrality, including:
[0097] First, the degree of each node is calculated, that is, the number of nodes directly connected to it. Nodes with high node degrees have higher connectivity in the network and are suitable as proxy nodes, that is, nodes with node degrees above the node degree threshold are retained.
[0098] Then the path length between any two nodes whose node degrees meet the requirements is calculated to evaluate the connectivity of the network. The path length refers to the number of hops of the shortest path between two nodes, and the calculation method is the Dijkstra algorithm. Nodes with short path lengths respond faster to the resource discovery process, that is, nodes with shortest path lengths shorter than the path threshold are retained.
[0099] Calculate the clustering coefficient of each node whose path length meets the requirements, and evaluate the connection density of the node among its neighbors. Nodes with high clustering coefficients usually have good local connectivity and are suitable as proxy nodes. The specific calculation method of clustering coefficient is as follows:
[0100]
[0101] in, Is a node The actual number of connections between neighbors, Is a node The degree.
[0102] Finally, the betweenness centrality of each node that meets the clustering coefficient requirement is calculated to evaluate the criticality of the node in the network. Nodes with high betweenness centrality play an important role in the network and are suitable as proxy nodes. Nodes with betweenness centrality higher than the set threshold are retained. The clustering coefficient calculation method is as follows:
[0103]
[0104] in, It is a slave node To Node The total number of shortest paths, It passes through the node The number of shortest paths. The calculation steps include:
[0105] ①For each pair of nodes (s, t), calculate all shortest paths.
[0106] ②Count the nodes passed The number of shortest paths .
[0107] ③Calculate the betweenness centrality of all node pairs (s, t).
[0108] Step 1.2.2: Analyze the nodes selected in step 1.2.1 and select the candidate proxy nodes that meet the conditions. The specific method is as follows:
[0109] Node attribute analysis mainly evaluates the specific performance indicators of each node in order to select the most suitable proxy node. The specific steps include: performance indicator collection, performance scoring, and comprehensive score calculation.
[0110] The collected performance indicators include: ① computing power, i.e., the hardware configuration of each node, such as CPU, memory, and storage, as well as the current load;
[0111] ② Network connection quality. That is, the network connection quality of each node, including bandwidth, latency, packet loss rate, etc.; ③ Stability, that is, stability indicators such as the historical failure rate and mean time between failures (MTBF) of each node.
[0112] The corresponding performance score is calculated based on the collected performance indicators. The calculation score mainly considers factors such as CPU utilization and memory utilization:
[0113]
[0114] The network score mainly considers factors such as bandwidth, latency and packet loss rate:
[0115]
[0116] The stability score mainly considers the historical failure rate and MTBF of each node:
[0117]
[0118] The comprehensive score of each node is calculated based on the weighted sum of each performance score. The comprehensive score is shown below:
[0119]
[0120] Among them, α, β and γ are the weight coefficients of each score, which can be adjusted according to actual needs.
[0121] Finally, potential proxy nodes are screened from all nodes based on the comprehensive scores to generate a set of candidate proxy nodes to ensure that these nodes have advantages in network topology and performance. At the same time, since the network environment and node status are dynamically changing, the proxy node selection scheme needs to be regularly evaluated and adjusted. There is an adjustable evaluation cycle T. At the end of each evaluation cycle, node selection and configuration are re-performed based on the latest network status and node performance.
[0122] Step 2: Establish a two-layer planning model for cloud access network computing resource discovery;
[0123] The decision characteristics of the two-level planning model for cloud access network computing resource discovery are derived from the optimization objectives and decision forms of the model. A two-level planning model for cloud access network computing resource discovery is established based on the decision characteristics. The upper-level planning model mainly performs targeted network topology design for the network state migration problem of cloud access network computing resources. The lower-level planning model optimizes the selection of timely node operation modes under the target drive of total energy consumption and the constraints of resource information status flags.
[0124] Furthermore, the main task of the upper-level planning model is to optimize the selection of proxy nodes, with the goal of minimizing the selection and communication time costs of proxy nodes. By analyzing the network topology and node attributes, appropriate proxy nodes are selected to ensure the accuracy and efficiency of the resource discovery process. The specific steps are as follows:
[0125] Construct an optimization model objective function, which is to minimize the total time cost required to select proxy nodes and establish connections;
[0126] Determine the constraints for the optimization model:
[0127] Each computing node has at least one proxy node to proxy resource information;
[0128] Uniqueness and logic constraints on proxy node selection.
[0129] Specifically, the upper-level planning model includes equations (1) to (7). Equation (1) is the objective function of the upper-level planning model. The two terms of the upper-level planning model objective function represent the total time for the cloud access network system to query the proxy node configuration in the whole process, and the total time for the ordinary computing node to establish a connection with the query proxy node.
[0130] (1),
[0131] (2),
[0132] (3),
[0133] (4),
[0134] (5),
[0135] (6),
[0136] (7),
[0137] Among them, in the formula, is a time collection, which is a sequence of time points for the project within the time window. Indicates a point in time, , Indicates the total number of time points, represents the set of computing nodes in the cloud access network, Represents the set of proxy nodes in the cloud access network computing nodes, Represents the cloud access network computing node proxy node The configuration time required, Indicates the time required to establish a connection between the computing node and the proxy node of the cloud access network. is the decision variable, the decision variable A value of 1 indicates that for The time window A resource-adaptive node is selected and configured as a resource-adaptive node for expansion balancing. As a cloud access network computing node with a specified configuration; decision variables A value of 0 indicates a cloud access network computing node that has not been selected by any node. is the decision variable, the decision variable 1 means that for a certain time point Resource adaptation, node The resource scheduler runs in management mode, that is, active mode, and the decision variable 0 means passive mode. is the decision variable, the decision variable 1 indicates that the node is calculated at a certain time point Selected as a computing node for expansion resource adaptation; decision variables 0 means not selected;
[0138] Formula (2) represents the validity premise, that is, for resource demand type m within time window k, a query proxy node is established to meet the network resource discovery requirements. Formula (3) represents the coverage premise of resource type information, that is, for resource demand type m within time window k, there is at least one connection between the query proxy node and the ordinary computing node. Formula (4) means that for any ordinary computing node i, no matter how it moves in different time windows, there is only one query proxy node connected to it. Formula (5) represents the logical premise, that is, for resource demand type m within time window k, the premise of the connection between the query proxy node and the ordinary computing node is the establishment of the query proxy node. Formulas (6) to (7) define constraints for decision variables.
[0139] Furthermore, the main task of the lower-level planning model is to run the resource discovery mode and optimize energy consumption according to the proxy node configuration determined by the upper-level planning model. The specific operation steps are as follows:
[0140] Construct the optimization objective of the lower-level planning model. The goal of the lower-level planning model is to minimize the total energy consumption in the resource discovery process while ensuring the efficiency of resource discovery.
[0141] Determine the constraints of the lower-level planning model: ensure that each computing node has at least one proxy node to proxy resource information to meet the constraints.
[0142] Specifically, the lower-level planning model optimizes the selection of node operation mode under the target drive of total energy consumption and the constraint of resource information status flag. Formula (8) represents the objective function of the lower-level planning model, which is the total energy consumption of cloud access network resource discovery in the whole process.
[0143] (8),
[0144] (9),
[0145] (10),
[0146] (11),
[0147] (12)
[0148] in, For the The node resource management requirements at a time point, the energy consumption of node i in the active mode to complete the resource scheduling process, For the node resource management requirements at the kth time point, the energy consumption of node i in the passive mode to complete the resource scheduling process is: Indicates the contribution of node i to the resource discovery information state when it chooses passive mode. The minimum total threshold of resource information status flags required by the cloud access network system in passive mode. is the minimum total threshold of the resource information status flag required by the cloud access network system in active mode; Formula (9) represents the logical premise of the computing node resource discovery operation mode, that is, only when the computing node i establishes a connection with the query proxy node, the computing node can choose the passive mode, otherwise the computing node can only choose the autonomous mode. Formula (10) is the threshold constraint of the resource information status flag of the cloud access network system, that is, the lower limit of the expected value of the total of the resource information status flag of the cloud access network system in passive mode. Formula (11) is the threshold constraint of the resource information status flag of the cloud access network system, that is, the lower limit of the expected value of the total of the resource information status flag of the cloud access network system in autonomous mode. Formula (12) is the decision variable definition constraint, that is, the two resource discovery modes.
[0149] In a further embodiment, for The energy consumption of node i in active mode to complete the resource scheduling process is calculated as follows:
[0150]
[0151] in, is the duration of the detection cycle, is the energy consumption of each query request; It is the total number of times all nodes successfully detect new resources in a detection cycle.
[0152] For the node resource management requirements at the kth time point, the energy consumption of node i in the passive mode to complete the resource scheduling process is calculated as follows:
[0153]
[0154] in is the total number of nodes in the network participating in resource discovery; is the expected state of the node; is the energy consumption per received data packet.
[0155] Step 3: Use the improved multi-objective particle swarm optimization algorithm to solve the bi-level programming model and determine the proxy nodes and resource discovery mode involved in resource discovery;
[0156] Step 31: Initialization
[0157] Randomly initialize particle population That is, a number of particles are randomly generated in the solution space. The initial position of each particle is and speed Initialize the optimal position of each particle and the global optimal position .
[0158] Step 32: Each solution of the two-level programming model includes power consumption and time cost, with power consumption as the horizontal axis and time cost as the vertical axis;
[0159] The dominance relationship between individuals is determined according to the Pareto dominance relationship, and the Euclidean distance from the corresponding coordinates of each solution to the Pareto frontier is calculated. The minimum value of the Euclidean distance is taken as the distance from the solution to the Pareto frontier and used as the fitness. The Pareto frontier consists of a group of non-dominated solutions, and each solution in the group is a non-dominated solution in the multi-objective optimization of the bi-level programming model.
[0160] Step 33: Update particle speed and position. The specific formula is:
[0161]
[0162]
[0163] In the formula, Indicates In the iteration The speed of a particle, represents the inertia weight, It is In this iteration The speed of a particle, is the current iteration number, is the individual learning factor, controlling the particle to its optimal position The degree of mobility, is the social learning factor, controlling the particle to move to the global optimal position The degree of mobility, and It is a random number between 0 and 1 used to ensure the randomness and diversity of the algorithm. is the optimal position found by the jth particle in the historical iteration process, is the optimal position found by all particles in the historical iteration process, No. In the iteration The position of a particle;
[0164] Step 34: Update the optimal position of each particle according to the local fitness and the global optimal position before the disturbance ;
[0165] Individual optimal position update, if the particle position of the current iteration The fitness is better than the previous optimal position The fitness of the individual is updated for , the individual optimal position The best position before ;
[0166] The global optimal position is updated. If the particle position of the current iteration The fitness is better than the previous global optimal position The fitness of the global optimal position before the disturbance is updated for , update the global optimal position before disturbance is the previous global optimal position ;
[0167] Step 35: Update the global optimal position before the disturbance Make a small perturbation, the specific formula is:
[0168]
[0169] in, is a random perturbation, which is used to introduce random changes in the optimization process to help the algorithm escape from the local optimum. is the updated global optimal position;
[0170] Step 36: Determine the termination condition
[0171] If the updated particle position reaches the maximum number of iterations or the convergence condition, proceed to step 37, otherwise return to step 32.
[0172] Step 37: Remove the dominated solutions in the external archive, and based on the updated archive, continue to screen and retain the non-dominated solutions in the external archive, and update the archive.
[0173] Step 4: According to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, select the proxy node and configure it.
[0174] Step 5: According to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, the resource discovery mode of each proxy node is selected, and the corresponding resource discovery mode is run to search for network resource information and transmit the resource information list to all nodes.
[0175] Step 5.1: After configuring the proxy node, the resource discovery process enters the resource discovery mode phase. This step selects the resource discovery mode of each proxy node based on the result of solving the bi-level programming model using the improved multi-objective particle swarm optimization algorithm, and runs the corresponding resource discovery mode. The proxy node runs the resource discovery mode according to the selected mode (active or passive), sends query requests or waits for external event triggers to obtain resource information of each node in the network.
[0176] Furthermore, the external event triggering mode of the query proxy node includes active query and passive query:
[0177] Active query is in active mode, the proxy node will actively send query requests periodically or according to specific conditions. Trigger conditions may include preset time intervals, changes in resource status, or instructions from system administrators. Passive query is in passive mode, and the query action is triggered by external events. For example, when a new resource joins the network or an existing resource changes, the proxy node will receive an update notification and query.
[0178] Specifically, the query steps of the query proxy node include: sending query requests, collecting resource information, and data processing and updating. First, the proxy node sends query requests to other nodes in the network to obtain the latest resource information. The query request can be sent in broadcast, unicast or multicast mode, and the specific choice depends on the network topology and resource distribution. After receiving the query request, other nodes will return their current resource status information, including CPU utilization, memory utilization, network bandwidth, delay, packet loss rate, etc. This information is transmitted back to the proxy node through the network. After the proxy node receives the resource information, it needs to process and update the data. The processing steps include data verification, deduplication, merging and storage. Among them, ① data verification needs to check whether the received data is complete and correct, and eliminate invalid or erroneous data; ② data deduplication means that if multiple nodes return the same resource information, the data needs to be deduplicated to retain the latest or most accurate data; ③ data merging means merging the resource information returned by multiple nodes to form a complete resource status view; ④ data storage means updating the processed resource information to the resource information list of the proxy node to ensure the real-time and accuracy of the information.
[0179] Active mode resource discovery: In active mode resource discovery, proxy nodes will periodically or actively send query requests to detect the resource status in the network as needed. These proxy nodes actively send query requests to other nodes, collect resource information and update the resource information list. In this process, in order to minimize the fluctuation of network traffic caused by detection as much as possible, while ensuring that the resource status is updated at all times. Set a detection period as T, and the number of times the node performs resource detection tasks during this period is extremely 𝑁 𝑎𝑠𝑘 For any node 𝑖 in the network, its detection frequency can be calculated by the following formula:
[0180]
[0181] To minimize the network load caused by probing, nodes take into account network conditions and resource change rates when determining their probing frequency 𝑁𝑎𝑠𝑘(𝑖). If resources change frequently or nodes need to join or leave the network frequently, the node's probing frequency may be relatively high. During each probing cycle of resource discovery, the node initiates queries based on a list of known resource information. For each successful probe, the node updates its internal resource information list. For a time window 𝑇, the expected number of successful probes 𝐸 can be given by:
[0182]
[0183] Among them, 𝑁 is the total number of nodes participating in resource detection in the network, 𝑃 𝑖 is the probability that node 𝑖 successfully discovers a new resource within time window 𝑇.
[0184] Resource discovery in passive mode: In passive mode resource discovery, the update of its information resource list is usually triggered by external events rather than actively seeking the latest information. In passive mode, the computing nodes in the cloud access network system only update their status when they receive new data or new task requests. In the cloud access network system, each computing node can receive and process data. The status update of the computing node is determined by the transmission of its neighboring nodes, that is, when a computing node receives data from a neighboring node, it will update its own resource information list. In this mode, the search and feedback of resources will be forwarded step by step to achieve the maximum node traversal retrieval. In order to ensure that the resource search and discovery has a wider coverage while saving the resource discovery search cost, it is necessary to limit the maximum forwarding hop count (HopCount, HC). The setting of HC must meet the requirement that the information discovered by the resource search can reach every node in the cloud access network system, while avoiding energy waste in the search and discovery process. And each node maintains a probability distribution 𝑃 𝑛, where 𝑛 represents the probability of reaching the node after 𝑛 hops. The sum of the probabilities of all hops of the node is 1, expressed as:
[0185]
[0186] When a node receives a data packet, assuming that the probability of each hop is 𝑃𝑛, the expected state 𝐸 of the node can be expressed by the following formula:
[0187]
[0188] Here, 𝑞 represents the probability of successfully receiving a data packet and updating the state accordingly, while 1−𝑞 represents the probability of not receiving a data packet. The 𝐸(𝑞) represents the expected state of the node calculated based on the probability distribution of the received data packets.
[0189] Specifically, for a cloud access network system with 𝑁 network nodes. The node set is represented by N={n|n=1,2,…,nmax}. Assume that the time point required in a resource discovery cycle is k, where time point K={k|k=1,2,…,kmax}. For a resource discovery process, the total number of network nodes in the kth time window is Num_node(k). There are computing nodes and control nodes in the cloud access network system. In a complex cloud access network system environment, some ordinary computing nodes will also have a higher degree. These nodes usually have better connectivity and accessibility. They may be more suitable for resource query service agents than control nodes. The resource information of other nodes is proxied to the release of resource availability information of such nodes, which are called proxy nodes. Time points refer to the specific time or time interval when the system needs to perform resource discovery operations during the resource discovery cycle. These time points are usually pre-set to ensure that the system can regularly check and update resource status to cope with dynamically changing network environments.
[0190] Step 5.2: After configuring the proxy node, the resource discovery process enters the stage of searching for network resource information. This step includes collecting and synchronizing resource information.
[0191] Step 5.2.1: The proxy node sends query requests to other nodes to collect their current resource status information, including CPU utilization, memory utilization, network bandwidth, latency, and packet loss rate. The specific operations are as follows:
[0192] Send a query request:
[0193] The proxy node uses a preset time interval or trigger condition to send query requests to other computing nodes in the network through broadcast, unicast or multicast.
[0194] The query request contains the type of resource status information that needs to be collected, such as CPU utilization, memory utilization, network bandwidth, delay, and packet loss rate.
[0195] Receive query request:
[0196] After receiving the query request, other computing nodes parse the request content and prepare corresponding resource status information.
[0197] Collect resource status information:
[0198] Each computing node collects the current resource status information and generates a response data packet, which contains the node's unique identifier, CPU utilization, memory utilization, network bandwidth, latency, packet loss rate and other detailed information.
[0199] Return response data packet:
[0200] The computing node sends the response data packet back to the proxy node. During the transmission process, the integrity and correctness of the data packet are ensured.
[0201] Step 5.2.2: Process and synchronize resource information:
[0202] Perform data verification on the collected resource information to check the integrity and correctness of the data. The proxy node verifies the received response data packet to ensure that the data packet has not been tampered with or lost. Specifically, data verification uses verification mechanisms such as checksums to check the integrity and correctness of the data packet and eliminate invalid or erroneous data packets;
[0203] Duplicate data is deduplicated to keep the latest or most accurate data. Specifically, the proxy node deduplicates the received resource information. If multiple nodes return the same resource information, the proxy node will keep the latest or most accurate data. Deduplication is based on timestamps or other unique identifiers to ensure the uniqueness of each resource information.
[0204] The resource information returned by multiple nodes is merged to form a complete resource status view. Specifically, the proxy node merges the deduplicated resource information to form a complete resource status view. During the merging process, factors such as the computing power, network connection quality and stability of each node are considered to ensure the comprehensiveness and accuracy of the resource status view.
[0205] The processed resource information is updated to the resource information list of the proxy node to ensure the real-time and accuracy of the information. Specifically, the proxy node updates the processed resource information to the local resource information list to ensure that the data in the resource information list is up-to-date and accurate, so as to facilitate subsequent resource allocation and task scheduling.
[0206] Step 5.3: Transmit resource information list to all nodes
[0207] After completing resource discovery and information collection, the proxy node needs to synchronize the latest resource information list to all nodes.
[0208] Here is a detailed description of step 5.3:
[0209] Step 5.3.1. Organize and package resource information list
[0210] At this stage, the proxy node needs to organize and package the collected resource status information to ensure the integrity and accuracy of the information. The specific operations are as follows:
[0211] Information collation: The proxy node collects the latest resource status information from all nodes, including detailed data such as CPU utilization, memory utilization, network bandwidth, latency, and packet loss rate.
[0212] Data formatting: The sorted data needs to be packaged according to a predetermined format to facilitate subsequent transmission and parsing. Use JSON, XML and other formats to represent this data.
[0213] Integrity check: Before packaging the data, the proxy node needs to check the collected information to ensure the integrity and accuracy of the data. Use checksums or other verification mechanisms to verify the integrity of the data. If the data is found to be incomplete or erroneous, correct it or collect it again in a timely manner.
[0214] Step 5.3.2. Broadcast and distribution of resource information list
[0215] After completing data collation and packaging, the proxy node needs to distribute this information to all nodes:
[0216] Network broadcast: The proxy node distributes the packaged resource information list to all computing nodes and control nodes through network broadcast. Broadcasting is carried out through multicast or unicast.
[0217] Data transmission protocol: During the broadcast process, proxy nodes need to use reliable data transmission protocols to ensure the speed and reliability of information transmission. These protocols can handle packet loss and delay problems in data transmission, ensuring that data can be transmitted to each node completely and quickly.
[0218] Step 5.3.3 Information reception and update
[0219] After each node receives the resource information list broadcast by the proxy node, it needs to perform the following operations:
[0220] Information reception: Each node receives resource information lists by listening to broadcast messages. These broadcast messages can be received by setting a specific network port or IP address.
[0221] Local storage: After receiving resource information, each node needs to store this information in the local resource information table. During the storage process, the persistence and availability of the information must be ensured to avoid information loss.
[0222] Information update: Each node needs to update the latest resource information received to the local resource information table to ensure that the local resource information is synchronized with the global one.
[0223] Step 5.3.4 Synchronization and adjustment of system status
[0224] Based on the latest resource information, each node needs to synchronize and adjust the system status:
[0225] State synchronization: All nodes synchronize the system status according to the latest resource information list to ensure that each node has a consistent understanding of the resource status.
[0226] Resource allocation adjustment: Based on the updated resource information, each node can dynamically adjust the resource allocation strategy, for example, reallocate CPU and memory resources to optimize the overall system performance.
[0227] Task scheduling optimization: Each node can adjust the task scheduling strategy according to the latest resource status to ensure that the task is executed on the optimal node to improve the efficiency and performance of the system.
[0228] Step 5.3.5 Continuous monitoring and feedback
[0229] In order to ensure the efficient operation of the system, each node needs to be continuously monitored and fed back:
[0230] Synchronization check: Nodes regularly check the synchronization of resource information lists to ensure the timeliness and accuracy of information updates. The consistency of local information and global information can be verified through a periodic verification mechanism.
[0231] Performance monitoring: The cloud access network cluster monitors system performance and resource utilization to promptly identify and resolve potential problems. For example, by monitoring CPU and memory utilization, resource bottlenecks can be identified and adjusted in a timely manner.
[0232] Problem feedback: After discovering a problem, the node will promptly feedback to the agent node or control node for centralized processing and resolution to maintain efficient operation of the system.
[0233] The above steps can ensure that the proxy node can synchronize the latest resource information to all nodes in a timely and accurate manner, thereby ensuring the coordinated operation of the entire system and the optimal use of resources.
[0234] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the technical principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A computing resource discovery method based on a two-level programming model, It is characterized in that include: Step 1: Determine a candidate set of proxy nodes from all nodes participating in computing resource discovery in the cloud access network system; Step 2: Establish a two-layer planning model for cloud access network computing resource discovery, the two-layer planning model includes an upper-layer planning model and a lower-layer planning model, and the objective function and constraints of the upper-layer planning model are specifically: (1), (2), (3), (4), (5), (6), (7), In the formula, is a time collection, which is a sequence of time points for the project within the time window. Indicates a point in time, , Indicates the total number of time points, represents the set of computing nodes in the cloud access network, Represents the set of proxy nodes in the cloud access network computing nodes, Represents the cloud access network computing node proxy node The configuration time required, Indicates the time required to establish a connection between the computing node and the proxy node of the cloud access network. is the decision variable, the decision variable A value of 1 indicates that for The time window A resource-adaptive node is selected and configured as a resource-adaptive node for expansion balancing. As a cloud access network computing node with a specified configuration; decision variables A value of 0 indicates a cloud access network computing node that has not been selected by any node. is the decision variable, the decision variable 1 means that for a certain time point Resource adaptation, node The resource scheduler runs in management mode, that is, active mode, and the decision variable 0 means passive mode. is the decision variable, the decision variable 1 indicates that the node is calculated at a certain time point Selected as a computing node for expansion resource adaptation; decision variables 0 means not selected; The objective function and constraints of the lower-level planning model are specifically: (8), (9), (10), (11), (12), in, For the The node resource management requirements at a time point, the energy consumption of node i in the active mode to complete the resource scheduling process, is the energy consumption of node i in passive mode to complete the resource scheduling process for the node resource management requirement at the kth time point, Indicates the contribution of node i to the resource discovery information state when it chooses passive mode. The minimum total threshold of resource information status flags required by the cloud access network system in passive mode. It is the minimum total threshold of resource information status flags required by the cloud access network system in active mode; For The energy consumption of node i in active mode to complete the resource scheduling process is calculated as follows: , in, is the duration of the detection cycle, is the energy consumption of each query request; It is the total number of times all nodes successfully detect new resources in a detection cycle; For the node resource management requirements at the kth time point, the energy consumption of node i in the passive mode to complete the resource scheduling process is calculated as follows: , in is the total number of nodes in the network participating in resource discovery; is the expected state of the node; is the energy consumption of receiving each data packet; Step 3: Use the multi-objective particle swarm optimization algorithm to solve the two-level programming model and determine the proxy nodes and resource discovery mode involved in resource discovery. The specific method is as follows: Step 31: Randomly initialize the particle group and the initial position of each particle and speed At the same time, it is randomly initialized to initialize the individual optimal position of each particle and the global optimal position ; Step 32: Each solution of the two-level programming model includes power consumption and time cost, with power consumption as the horizontal axis and time cost as the vertical axis; The dominance relationship between individuals is determined according to the Pareto dominance relationship, and the Euclidean distance from the corresponding coordinates of each solution to the Pareto frontier is calculated. The minimum value of the Euclidean distance is taken as the distance from the solution to the Pareto frontier and used as the fitness. The Pareto frontier consists of a group of non-dominated solutions, and each solution in the group is a non-dominated solution in the multi-objective optimization of the bi-level programming model. Step 33: Update particle speed and position. The specific formula is: , , In the formula, Indicates In the iteration The speed of a particle, represents the inertia weight, It is In this iteration The speed of a particle, is the current iteration number, is the individual learning factor, controlling the particle to its optimal position The degree of mobility, is the social learning factor, controlling the particle to move to the global optimal position The degree of mobility, and It is a random number between 0 and 1 used to ensure the randomness and diversity of the algorithm. is the optimal position found by the jth particle in the historical iteration process, is the optimal position found by all particles in the historical iteration process, No. In the iteration The position of a particle; The dynamic adjustment formula of inertia weight is: , in, is the maximum value of the inertia weight, is the minimum value of the inertia weight, is the maximum number of iterations; Step 34: Update the optimal position of each particle according to the local fitness and the global optimal position before the disturbance ; Individual optimal position update, if the particle position of the current iteration The fitness is better than the previous optimal position The fitness of the individual is updated for , the individual optimal position The best position before ; The global optimal position is updated. If the particle position of the current iteration The fitness is better than the previous global optimal position The fitness of the global optimal position before the disturbance is updated for , update the global optimal position before disturbance is the previous global optimal position ; Step 35: Update the global optimal position Make a small perturbation, the specific formula is: , in, is the random disturbance, is the updated global optimal position; Step 36: If the updated particle position reaches the maximum number of iterations or the convergence condition, stop the iteration and proceed to step 37, otherwise return to step 32; Step 37: Remove the dominated solutions in the external archive, and continue to screen and retain the non-dominated solutions in the external archive according to the updated archive, and update the archive; Step 4: According to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, select the proxy node and configure it; Step 5: According to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, the resource discovery mode of each proxy node is selected, and the corresponding resource discovery mode is run to search for network resource information and transmit the resource information list to all nodes.
2. The computing resource discovery method based on the two-level programming model according to claim 1, It is characterized in that The specific method for determining the candidate set of proxy nodes from all nodes participating in computing resource discovery in the cloud access network system is as follows: Step 1.1: Initialize all nodes participating in computing resource discovery from the cloud access network system, and record basic information of each node, including unique identification, physical location, computing capacity, and current load; Step 1.2: By analyzing the network topology and node attributes, potential proxy nodes are screened out from all nodes and put into the proxy node candidate set.
3. The computing resource discovery method based on the two-level programming model according to claim 2, It is characterized in that By analyzing the network topology and node attributes, potential proxy nodes are screened out from all nodes and put into the candidate set of proxy nodes as follows: Collect information about all nodes and links in the network, build a topological graph, and perform topological characteristic analysis. Filter nodes in turn according to node degree, path length, clustering coefficient, and betweenness centrality. The comprehensive scores of the selected proxy nodes are calculated, and the proxy nodes with comprehensive scores greater than the set score threshold are added to the proxy node candidate set.
4. The computing resource discovery method based on the two-level programming model according to claim 3, It is characterized in that Clustering coefficient The calculation formula is: , in, Is a node The actual number of connections between neighbors, Is a node degree; Betweenness centrality of a node The calculation formula is: in, It is a slave node To Node The total number of shortest paths, It passes through the node The number of shortest paths.
5. The computing resource discovery method based on the two-level programming model according to claim 3, It is characterized in that Comprehensive rating of proxy nodes The calculation formula is: ; In the formula, For Node The stability score is , Give the node a network score, specifically , The calculation score of the node is , , and is the weight coefficient of each score.
6. A computing resource discovery system based on a two-level programming model, It is characterized in that include: The proxy node determination module is used to determine a set of proxy node candidates from all nodes participating in computing resource discovery in the cloud access network system; A two-layer planning model, the two-layer planning model includes an upper-layer planning model and a lower-layer planning model, the upper-layer planning model is used to perform targeted network topology design for the network state migration problem of cloud access network computing resources, and the lower-layer planning model is used to optimize the selection of timely node operation modes under the target drive of total energy consumption and the resource information state flag constraint; the objective function and constraints of the upper-layer planning model are specifically: (1), (2), (3), (4), (5), (6), (7), In the formula, is a time collection, which is a sequence of time points for the project within the time window. Indicates a point in time, , Indicates the total number of time points, represents the set of computing nodes in the cloud access network, Represents the set of proxy nodes in the cloud access network computing nodes, Represents the cloud access network computing node proxy node The configuration time required, Indicates the time required to establish a connection between the computing node and the proxy node of the cloud access network. is the decision variable, the decision variable A value of 1 indicates that for The time window A resource-adaptive node is selected and configured as a resource-adaptive node for expansion balancing. As a cloud access network computing node with a specified configuration; decision variables A value of 0 indicates a cloud access network computing node that has not been selected by any node. is the decision variable, the decision variable 1 means that for a certain time point Resource adaptation, node The resource scheduler runs in management mode, that is, active mode, and the decision variable 0 means passive mode. is the decision variable, the decision variable 1 indicates that the node is calculated at a certain time point Selected as a computing node for expansion resource adaptation; decision variables 0 means not selected; The objective function and constraints of the lower-level planning model are specifically: (8), (9), (10), (11), (12), in, For the The node resource management requirements at a time point, the energy consumption of node i in the active mode to complete the resource scheduling process, is the energy consumption of node i in passive mode to complete the resource scheduling process for the node resource management requirement at the kth time point, Indicates the contribution of node i to the resource discovery information state when it chooses passive mode. The minimum total threshold of resource information status flags required by the cloud access network system in passive mode. It is the minimum total threshold of resource information status flags required by the cloud access network system in active mode; For The energy consumption of node i in active mode to complete the resource scheduling process is calculated as follows: , in, is the duration of the detection cycle, is the energy consumption of each query request; It is the total number of times all nodes successfully detect new resources in a detection cycle; For the node resource management requirements at the kth time point, the energy consumption of node i in the passive mode to complete the resource scheduling process is calculated as follows: , in is the total number of nodes in the network participating in resource discovery; is the expected state of the node; is the energy consumption of receiving each data packet; The bi-level programming model solving module is used to solve the bi-level programming model using the multi-objective particle swarm optimization algorithm to determine the proxy nodes and resource discovery mode involved in resource discovery. The specific method is as follows: Step 31: Randomly initialize the particle group and the initial position of each particle and speed At the same time, it is randomly initialized to initialize the individual optimal position of each particle and the global optimal position ; Step 32: Each solution of the two-level programming model includes power consumption and time cost, with power consumption as the horizontal axis and time cost as the vertical axis; The dominance relationship between individuals is determined according to the Pareto dominance relationship, and the Euclidean distance from the corresponding coordinates of each solution to the Pareto frontier is calculated. The minimum value of the Euclidean distance is taken as the distance from the solution to the Pareto frontier and used as the fitness. The Pareto frontier consists of a group of non-dominated solutions, and each solution in the group is a non-dominated solution in the multi-objective optimization of the bi-level programming model. Step 33: Update particle speed and position. The specific formula is: , , In the formula, Indicates In the iteration The speed of a particle, represents the inertia weight, It is In this iteration The speed of a particle, is the current iteration number, is the individual learning factor, controlling the particle to its optimal position The degree of mobility, is the social learning factor, controlling the particle to move to the global optimal position The degree of mobility, and It is a random number between 0 and 1 used to ensure the randomness and diversity of the algorithm. is the optimal position found by the jth particle in the historical iteration process, is the optimal position found by all particles in the historical iteration process, No. In the iteration The position of a particle; The dynamic adjustment formula of inertia weight is: , in, is the maximum value of the inertia weight, is the minimum value of the inertia weight, is the maximum number of iterations; Step 34: Update the optimal position of each particle according to the local fitness and the global optimal position before the disturbance ; Individual optimal position update, if the particle position of the current iteration The fitness is better than the previous optimal position The fitness of the individual is updated for , the individual optimal position The best position before ; The global optimal position is updated. If the particle position of the current iteration The fitness is better than the previous global optimal position The fitness of the global optimal position before the disturbance is updated for , update the global optimal position before disturbance is the previous global optimal position ; Step 35: Update the global optimal position Make a small perturbation, the specific formula is: , in, is the random disturbance, is the updated global optimal position; Step 36: If the updated particle position reaches the maximum number of iterations or the convergence condition, stop the iteration and proceed to step 37, otherwise return to step 32; Step 37: Remove the dominated solutions in the external archive, and continue to screen and retain the non-dominated solutions in the external archive according to the updated archive, and update the archive; The proxy solution configuration module is used to select and configure proxy nodes based on the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm; The resource discovery mode operation module is used to select the resource discovery mode of each proxy node according to the solution results of the resource discovery bi-level programming model by the multi-objective particle swarm optimization algorithm, and run the corresponding resource discovery mode to search for network resource information and transmit the resource information list to all nodes.
Citation Information
Patent Citations
Distributed energy storage device scheduling method and device based on centerless particle swarm algorithm
CN110932297A
Double-layer collaborative optimization configuration method and system for the energy storage capacity of an optical storage system
CN113792911A
Energy storage locating and sizing double-layer model optimization method for power distribution network containing distributed power supply
CN117578531A
Power distribution network multi-target bilevel planning method considering energy storage and demand response
CN118336742A
