Edge computing network service cache updating method considering switching cost
By constructing a multi-slot model of the edge collaborative network and using convex optimization methods, combined with dynamic regret assessment and online backoff prediction algorithms, the cache update of the edge computing network is optimized, solving the switching cost problem and improving system performance and service quality.
Patent Information
- Application Number
- CN202411398288.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-09
- Publication Date
- 2025-01-10
- Estimated Expiration
- 2044-10-09
AI Technical Summary
The existing edge computing service cache update mechanism does not take into account the service switching cost, resulting in frequent replacement of services with high switching costs, increasing system overhead, and the existing strategy is complex and difficult to apply in real time.
A multi-timeslot model of the edge collaborative network is constructed, and three processing methods for offloading tasks to the edge server are defined. Combining convex optimization methods and dynamic regret evaluation, the decision-making process is optimized through online gradient descent and projection ascent algorithms. Considering the switching cost, an online backoff prediction algorithm is used for cache updates.
Reduce latency and service costs, improve system performance and service quality, dynamically adapt to changes in task requests and caching needs, and provide flexible caching strategies.
Smart Images

Figure CN119299457A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of edge computing technology, and in particular to an edge computing network service cache update method taking switching costs into consideration. Background Art
[0002] With the development of IoT (Internet of Things) and 5G technology, edge computing, as a computing model that sinks computing power to the edge of the network, has attracted more and more attention. Edge computing can significantly reduce network latency, improve service response speed and overall user experience by processing data on edge nodes close to the data source. In edge computing, service caching is one of the key technologies to improve system performance and efficiency. Service caching reduces data transmission latency and bandwidth consumption by storing commonly used services and data on edge nodes.
[0003] However, edge computing service caching faces many challenges in practical applications, mainly including the following aspects: First, the cache space is limited. The storage resources of edge nodes are relatively limited, and it is impossible to cache all services and data that may be requested. Therefore, how to store as many high-frequency access services as possible in a limited cache space becomes an important issue; second, dynamics and heterogeneity. In an edge computing environment, user requests are highly dynamic and heterogeneous, and user requests at different times and places may be very different, which puts higher requirements on caching strategies; third, the switching cost problem. In practical applications, the update and replacement process of the service cache will introduce certain switching costs, which include computing resource consumption, data migration overhead, and service interruption. If these switching costs are not effectively managed, it may lead to system performance degradation and worse user experience.
[0004] The edge computing service cache update mechanism currently proposed does not consider the service switching cost, and may frequently replace services with high switching costs, thereby increasing system overhead. In addition, some edge computing service cache strategies currently proposed based on switching costs are highly complex and difficult to apply in real time in practice. Summary of the invention
[0005] In response to the above technical problems, an embodiment of the present application proposes an edge computing network service cache update method that takes switching costs into consideration, fully considers the switching costs caused by cache strategy updates at different times, and comprehensively considers different processing methods for offloading tasks to edge servers. The discrete decision model is converted into a continuous decision model, and the optimal strategy is solved using a convex optimization method. It is combined with a dynamic regret evaluation method to continuously optimize the decision-making process, thereby improving system performance and service quality, and reducing latency and service costs.
[0006] In order to achieve the above-mentioned purpose, an embodiment of the present application proposes a method for updating the cache of an edge computing network service considering the switching cost, comprising the following steps: constructing an edge collaborative network multi-time slot model, defining three processing methods for offloading tasks to edge servers, and dynamically updating cache content in different time slots; wherein the edge collaborative network multi-time slot model is composed of several clients, several edge servers, a central controller and an edge collaborative network, and the three processing methods are direct processing on the edge server side, collaborative processing on the edge server side, and downloading processing from the cloud; constructing a cost model for the entire Internet of Things system; wherein the cost of the entire Internet of Things system includes the delay cost of processing the user arrival task in the current time slot, and the switching cost of the change of the cache application set in the next time slot; formulating the cache network strategy selection problem as an online convex optimization problem with a switching cost, and using dynamic regret as an evaluation indicator; under the condition of no prediction, using the online gradient descent algorithm and the online gradient projection ascent algorithm to achieve the minimum dynamic regret of the Internet of Things system; performing a backoff update based on an online backoff prediction algorithm with a prediction window size of W, and finally obtaining the optimal decision, and performing an edge computing network service cache update based on the obtained optimal decision.
[0007] In order to achieve the above-mentioned purpose, the embodiment of the present application also proposes an edge computing network service cache update system considering the switching cost, including: a basic construction module, which is used to construct an edge collaborative network multi-time slot model, define three processing methods for offloading tasks to edge servers, and dynamically update cache content in different time slots, wherein the edge collaborative network multi-time slot model is composed of several clients, several edge servers, a central controller and an edge collaborative network, and the three processing methods are direct processing on the edge server side, collaborative processing on the edge server side, and download processing from the cloud; a cost model construction module, which is used to construct a cost model of the entire Internet of Things system, wherein the entire The cost of the IoT system includes the delay cost of processing the user arrival task in the current time slot and the switching cost of the change of the cache application set in the next time slot; the convex optimization problem conversion module is used to express the cache network strategy selection problem as an online convex optimization problem with switching cost, and uses dynamic regret as the evaluation indicator; the no-prediction module is used to use the online gradient descent algorithm and the online gradient projection ascent algorithm to achieve the minimum dynamic regret of the IoT system under no-prediction conditions; the backoff update module is used to perform backoff updates based on the online backoff prediction algorithm with a prediction window size of W, and finally obtain the optimal decision, and update the edge computing network service cache based on the obtained optimal decision.
[0008] In order to achieve the above-mentioned purpose, an embodiment of the present application also proposes an electronic device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute an edge computing network service cache update method that considers switching costs as described above.
[0009] In order to achieve the above objectives, an embodiment of the present application also proposes a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it can implement an edge computing network service cache update method that considers switching costs as described above.
[0010] The embodiment of the present application proposes an edge computing network service cache update method considering switching costs, which is suitable for some delay-sensitive scenarios and resource-constrained application scenarios, such as real-time traffic information processing, real-time data analysis in medical health monitoring systems, and real-time AR / VR data processing in games and entertainment. The method takes into account the switching costs of cache strategy updates at different times, and proposes a cost model including the delay cost of processing user arrival tasks in the current time slot and the switching cost of the cache application set change in the next time slot, which is more in line with the actual scenario. An edge collaborative network multi-time slot model is constructed, and the edge collaborative network is introduced to comprehensively consider the three processing methods of offloading tasks to the edge server, namely, direct processing at the edge, collaborative processing at the edge, and download processing from the cloud. Convex optimization is used when solving. By converting the discrete decision model into a continuous model, the convex optimization method is used to solve the optimal strategy, and combined with the dynamic regret evaluation method, the decision process is continuously optimized to improve system performance and service quality. An online backoff prediction algorithm based on a prediction window size of W is used for backoff updates, which can dynamically adapt to changes in task requests and cache requirements, and provide a more flexible cache strategy.
[0011] Optionally, in the edge cooperative network multi-time slot model, the client offloads the task to a nearby local edge server, and the local edge server provides services locally, that is, direct processing on the edge server side is adopted; if the local edge server does not cache the microservices required by the user, the corresponding task is transferred to the nearby neighbor edge server that has cached the microservices required by the client, and the neighbor edge server feeds back to the local edge server and the client after processing, that is, edge server-side collaborative processing is adopted; if all neighbor edge servers do not cache the microservice set required by the client, the corresponding task is sent to the cloud for processing, that is, download processing from the cloud is adopted;
[0012] Define \(T\) as the working time of the edge server, \(t\) as the content update time of the edge server cache, and \(N\) t represents the number of \(t\) in \(T\), \(T / t = N\) t , define \(r_f\) as the time for the edge server to process a single task unloaded by the client, which is the duration of 10 radio frames. Assume that the edge server associated with the client does not change in each radio frame, and the client moves among different \(t\) and the association relationship with the edge server changes;
[0013] Assume that there are \(N\) edge servers in the edge cooperation network, \(N\) is an integer greater than 1. Each edge server processes the client arrival tasks within \(T\), and the cache capacity of each edge server is \(M\), \(M\) is an integer greater than 1. The microservice set cached by the \(i\)-th edge server is \(S\) i , \(S\) i =\([s\) i1 , \(s\) i2 ,…, \(s\) im , \(m < M\). The total microservice set cached by the entire edge cooperation network is \(H\) im , \(H\) im =\([s\) 11 , \(s\) 12 ,…, \(s\) i1 , \(s\) i2 ,…, \(s\) n1 , \(s\) n2 ,…, \(s\) nm ;
[0014] Assume that the edge server can only dynamically adjust its cached microservice set according to the processing situation of the previous \(t\) at the beginning of each \(t\). Let \(x\) i,T =\([X\) i,1 , \(X\) i,2 ,…, \(X\) i,t ,…, \(X\) i,T be the cache decision of the \(i\)-th edge server throughout \(T\), and \(X\) i,t be the specific cache decision set of the \(i\)-th edge server at time \(t\), \(X\) i,t =\([x\) i,1,t , \(x\) i,2,t ,…, \(x\) i,m,t . Each edge server hopes to select the optimal cache decision at each \(t\) to meet the QoS requirements of the client offloading tasks.
[0015] Optionally, assume that at time slot \(t\), \(K\) tasks arrive and are offloaded to the edge server for processing. The delay cost of the entire Internet of Things system at time slot \(t\) is expressed by the formula:
[0016]
[0017]
[0018] Among them, D k (x t ) represents the latency cost of the entire IoT system in time slot t, local means processing directly on the edge server, collaborate means collaborative processing on the edge server, cloud means downloading from the cloud, μ k represents the CPU cycles required to complete task k, f i represents the CPU frequency of the ith edge server, represents the uplink transmission time of task k, represents the time for the collaborative edge server to process task k, s k represents the data size of task k, r k represents the transmission speed of task k in the uplink, φ represents the sub-band bandwidth, P i represents the uplink transmission power of the edge server, h i represents the uplink channel gain between edge servers, N 0 represents the noise power spectral density, represents the time required to upload task k to the cloud, represents the time it takes for the cloud to process task k, p(k,cl) represents the shortest path to upload to the cloud, and d c represents the latency of the cloud network link, cl k Indicates the maximum processing speed of the cloud.
[0019] Optionally, the switching cost of the entire IoT system at time slot t is expressed by the formula:
[0020]
[0021] Among them, S(x t -x t-1 ) represents the switching cost of the entire IoT system at time slot t, x i,k,t and x i,k,t-1 They represent the caching decision of the i-th edge server for task k at time slot t and at time slot t-1, respectively.
[0022] Optionally, the cost model of the entire IoT system is expressed by the formula:
[0023]
[0024] Among them, cost(T) represents the cost of the entire IoT system in time slot T;
[0025] Dynamic regret is defined as the difference between the cost model of the entire IoT system and the given comparator sequence, which is expressed by the formula:
[0026]
[0027] Among them, Regret(u,T) represents dynamic regret.
[0028] Optionally, under the condition of no prediction, the online gradient descent algorithm and the online gradient projection ascent algorithm are used to achieve the minimum dynamic regret of the Internet of Things system, including:
[0029] Using the online gradient descent algorithm, the action at each moment is updated by the following formula:
[0030]
[0031] in, is the preset descending step length, Is the cache strategy x t-1 The gradient at
[0032] The cost function list is defined using the cumulative absolute difference of the stage optimizer in consecutive stages. The path length of the function list Path length grouping, defining the set Assume that the path length of all function lists is limited to L T , It is expressed by the formula:
[0033]
[0034] Among them, α is the preset interpolation coefficient. The shorter the path length, the better the performance of the online gradient descent algorithm.
[0035] For any function class and any set of lists of functions In online optimization problems involving switching costs, the dynamic regret upper bound of the online gradient descent algorithm is:
[0036]
[0037] in,
[0038] The update rule of the online gradient projection ascent algorithm is expressed by the formula:
[0039]
[0040] Among them, η t is the preset ascending step length, is the Euclidean projection of the parameter vector z on the feasible set Y, and ∥·∥ is the Euclidean normal form;
[0041] The dynamic regret upper bound of the online gradient projection ascent algorithm is:
[0042]
[0043] Where diam(y) represents the diameter of the feasible set Y, and L is the Lipschitz constant of the objective function gradient.
[0044] Optionally, a backoff update is performed based on an online backoff prediction algorithm with a prediction window size of W, and finally an optimal decision is obtained, including: defining the prediction window size W, the step size γ, the learning rate η, and initializing x 0 ; At time step s, use the output of the online gradient descent algorithm as the initial operation; starting from time step s+W, gradually update the value of each time step forward. The update of each time step is based on the gradient information of the current time step and is adjusted based on the previous time step. It is expressed by the formula: in, represents the cache decision value calculated at time step s; for s = tW-1,…,t, x is updated once per step t , the update rule is:
[0045]
[0046] After W steps of backward prediction update, the optimal decision is obtained. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the related technologies, the drawings required for use in the embodiments of the present application or the related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0048] Figure 1 It is a flowchart of an edge computing network service cache update method considering switching costs provided in one embodiment of the present application;
[0049] Figure 2 is a scene diagram of an edge collaboration network provided in an embodiment of the present application;
[0050] Figure 3 is a schematic diagram of a multi-slot model provided in an embodiment of the present application;
[0051] Figure 4 is a schematic diagram of a cache update provided in an embodiment of the present application;
[0052] Figure 5It is a structural diagram of an edge computing network service cache update system considering switching costs provided in another embodiment of the present application;
[0053] Figure 6 It is a structural schematic diagram of an electronic device provided in another embodiment of the present application. DETAILED DESCRIPTION
[0054] In order to make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the embodiments of the present application will be described in detail below in conjunction with the accompanying drawings. In the various embodiments of the present application, many technical details are proposed in order to make the reader better understand the present application. However, even without these technical details and various changes and modifications based on the following embodiments, the technical scheme claimed in the present application can also be implemented. The division of the following embodiments is only for the convenience of description, and the specific implementation mode of the present application should not constitute any limitation. The various embodiments can be combined with each other and referenced to each other under the premise of no contradiction.
[0055] An embodiment of the present application proposes an edge computing network service cache update method that takes switching costs into consideration, which is applied to a server (central controller). The implementation details of the edge computing network service cache update method that takes switching costs into consideration proposed in this embodiment are described in detail below. The following content is only the implementation details provided for ease of understanding and is not necessary for the implementation of this solution.
[0056] The specific process of the edge computing network service cache update method considering the switching cost proposed in this embodiment can be as follows: Figure 1 As shown, including:
[0057] Step 101, construct an edge collaborative network multi-slot model, define three processing methods for offloading tasks to edge servers, and dynamically update cache content in different time slots, wherein the edge collaborative network multi-slot model is composed of several clients, several edge servers, a central controller and an edge collaborative network. The three processing methods are direct processing on the edge server side, collaborative processing on the edge server side, and downloading processing from the cloud.
[0058] In the specific implementation, the server first builds the edge cooperation network multi-slot model. The edge cooperation network scenario can be as follows Figure 2As shown in FIG. 1 , the edge cooperative network multi-time slot model consists of several clients, several edge servers, a central controller, and an edge cooperative network on a remote cloud that provides different microservices. The edge server on the edge end caches a set of heterogeneous microservice sets. At each moment, the client offloads the task to the local edge server located near the client. The local edge server can provide services locally. This processing method is directly processed on the edge server end. If the local edge server does not cache the microservice required by the user, the corresponding task can be transferred to the neighbor edge server nearby that has cached the microservice required by the client. After the neighbor edge server completes the processing, it will feedback to the local edge server and the client. The neighbor edge server is connected through a local area network or a wired point-to-point connection. This processing method is the edge server-side collaborative processing. Through the collaboration between edge servers, the heterogeneous edge resources can be fully utilized to expand the cache capacity space to serve more clients (later). If all neighbor edge servers do not cache the microservice set required by the client, that is, the local edge server and the neighbor edge server cannot process it, the corresponding task can be sent to the cloud for processing. This processing method is downloading from the cloud.
[0059] In general, the update frequency of the microservice set in the edge server is usually much lower than the transmission rate of the edge server processing tasks. This is because the popularity of the microservice set changes slowly. Even if the microservice update frequency is low, it will not have a significant impact on the user experience because the newer data will usually remain valid for a longer period of time. Therefore, in order to better reflect the characteristics of the real scene, the server abstracts a Figure 3 The multi-slot model shown.
[0060] Based on the multi-time slot model, considering the replacement strategy before each time t, the cache microservice set is updated according to the different situations of user arrival tasks, such as Figure 4 As shown in the figure. From the system perspective, a central controller is set to coordinate the unified management of nodes or update strategies. The server defines T as the working time of the edge server, t as the update time of the edge server cache content, and N t Represents the number of t in T, T / t=N t At the same time, rf is defined to represent the time for the edge server to process a single task offloaded by the client, specifically the duration of 10 radio frames. It is assumed that the edge server associated with the client does not change in each radio frame. In different t, the client moves and the association relationship with the edge server changes.
[0061] Assume that there are N edge servers in the edge collaboration network, where N is an integer greater than 1. Each edge server processes the client arrival tasks within T. The cache capacity of each edge server is M, where M is an integer greater than 1. The set of microservices cached by the i-th edge server is S i , S i = [s i1 , s i2 , …, s im , where m < M. The total set of microservices cached by the entire edge collaboration network is H im , H im = [s 11 , s 12 , …, s i1 , s i2 , …, s n1 , s n2 , …, s nm ;
[0062] Assume that the edge server can only dynamically adjust the set of microservices cached by itself at the beginning of each t according to the processing situation in the previous t. Let x i,T = [X i,1 , X i,2 , …, X i,t , …, X i,T be the caching decision of the i-th edge server throughout T. X i,t is the specific caching decision set of the i-th edge server at time t. X i,t = [x i,1,t , x i,2,t , …, x i,m,t . Each edge server hopes to select the optimal caching decision at each t to meet the Qos requirements of the client offloading tasks.
[0063] Step 102: Construct the cost model of the entire Internet of Things system. Among them, the cost of the entire Internet of Things system includes the delay cost of processing the user arrival tasks in the current time slot and the switching cost of the change of the cached application set in the next time slot.
[0064] In a specific implementation, after the server completes the construction of the multi-time slot model of the edge collaboration network, it continues to construct the cost model of the entire Internet of Things system. Among them, the cost of the entire Internet of Things system includes the delay cost of processing the user arrival tasks in the current time slot and the switching cost of the change of the cached application set in the next time slot. The delay cost is further divided into the delay cost of direct processing at the edge server side, the delay cost of collaborative processing at the edge server side, and the delay cost of downloading and processing from the cloud according to the processing method.
[0065] Assume that at time slot t, K tasks arrive and are offloaded to the edge server for processing.
[0066] Regarding the latency cost of processing directly on the edge server (local computing latency cost). Assuming that the size of the task request is much smaller than the size of the task content, the time consumption of sending the request can be ignored. Indicates the time to directly offload to the local edge server to execute the current task, which can be obtained:
[0067]
[0068] Among them, D k (1) represents the latency cost of processing directly on the edge server, μ k represents the CPU cycles required to complete task k, f i Represents the CPU frequency of the i-th edge server.
[0069] About the latency cost of collaborative processing on edge servers. From the perspective of data transmission, the latency of collaborative processing on edge servers is It consists of three parts: the uplink transmission time of task k The time it takes for the collaborative edge server to process task k and the downlink transmission time for the neighbor edge server to transmit the result back to the client Since the result of the backhaul is usually much smaller than the uploaded data, and the downlink data transmission speed is much faster than the uplink transmission speed, it can be ignored. Based on this, we can get
[0070] Assuming that the uplink uses orthogonal frequency division multiple access (OFDMA), each client in the scene shares the frequency bandwidth resources through OFDMA and accesses the IoT system, dividing the frequency bandwidth B into K equal sub-bands, and the bandwidth of each sub-band is B / K. In order to ensure the orthogonality of the uplink transmission, each edge server occupies a sub-band, so a central controller can serve at most K edge servers at the same time. According to the Shannon-Hartley theorem calculation formula, the transmission speed r of task k in the uplink is k for:
[0071]
[0072] Where φ represents the sub-band bandwidth, P i represents the uplink transmission power of the edge server, h i represents the uplink channel gain between edge servers, N 0 represents the noise power spectral density.
[0073] From this we can get sk Indicates the data size of task k, including the size of the microservice code of task k and the size of input data.
[0074] Therefore, the latency cost of collaborative processing on the edge server can be written as:
[0075]
[0076] Among them, D k (2) represents the latency cost of collaborative processing on the edge server side.
[0077] Regarding the latency cost of downloading from the cloud. The task processing time (latency) at this time is the time required to upload task k to the cloud. The time it takes for the cloud to process task k and the downlink transmission time for the cloud to transmit the results back to the client Similarly, because the return time is very short, can be ignored, so the latency of downloading from the cloud can be written as:
[0078] Use d c represents the delay of the cloud network link, p(k,cl) represents the shortest path to upload to the cloud, then It can be expressed as:
[0079] Use cl k represents the maximum processing speed of the cloud, then It can be expressed as:
[0080] Therefore, the latency cost of downloading from the cloud can be written as:
[0081]
[0082] Among them, D k (3) represents the latency cost of downloading from the cloud.
[0083] Based on the above, the delay cost of the entire IoT system in time slot t can be expressed as:
[0084]
[0085] Among them, D k (x t ) represents the latency cost of the entire IoT system in time slot t, local means processing directly on the edge server, collaborate means collaborative processing on the edge server, cloud means downloading from the cloud, μ krepresents the CPU cycles required to complete task k, f i represents the CPU frequency of the ith edge server, represents the uplink transmission time of task k, represents the time for the collaborative edge server to process task k, s k represents the data size of task k, r k represents the transmission speed of task k in the uplink, φ represents the sub-band bandwidth, P i represents the uplink transmission power of the edge server, h i represents the uplink channel gain between edge servers, N 0 represents the noise power spectral density, represents the time required to upload task k to the cloud, represents the time it takes for the cloud to process task k, p(k,cl) represents the shortest path to upload to the cloud, and d c represents the latency of the cloud network link, cl k Indicates the maximum processing speed of the cloud.
[0086] It is understandable that the caching strategy in each time slot cannot always guarantee the best performance, that is, the minimum latency. We hope to optimize the caching strategy in each time slot through the central controller, which needs to be achieved by updating the cache set. However, updating the cache set will involve a certain cost, that is, the cost of downloading and installing, because switching from one state to another requires a certain cost, which is the switching cost. The switching cost of the entire IoT system in time slot t can be expressed by the formula:
[0087]
[0088] Among them, S(x t -x t-1 ) represents the switching cost of the entire IoT system at time slot t, x i,k,t and x i,k,t-1 They represent the caching decision of the i-th edge server for task k at time slot t and at time slot t-1, respectively.
[0089] Based on the delay cost and switching cost, the formula of the cost model of the entire IoT system can be expressed as:
[0090]
[0091] Among them, cost(T) represents the cost of the entire IoT system in time slot T.
[0092] Step 103, the cache network strategy selection problem is expressed as an online convex optimization problem with a switching cost, and dynamic regret is used as an evaluation indicator.
[0093] In the specific implementation, server selection formulates the cache network strategy selection problem as an online convex optimization (OCO) problem with switching cost. The OCO problem has significant advantages in dynamic environments and can handle decision-making problems at continuous moments well. This problem is also a practical online learning problem, and dynamic regret is often used as a performance indicator. Dynamic regret is defined as the difference between the cost model of the entire IoT system and a given comparator sequence, which is expressed by the formula:
[0094]
[0095] Among them, Regret(u,T) represents dynamic regret.
[0096] Step 104, under the condition of no prediction, using the online gradient descent algorithm and the online gradient projection ascent algorithm to achieve the minimum dynamic regret of the Internet of Things system.
[0097] In the process of achieving the minimum dynamic regret, we first use the online gradient descent algorithm to update the action at each moment through the following formula:
[0098]
[0099] in, is the preset descending step length, Is the cache strategy x t-1 The gradient at .
[0100] The cost function list is then defined using the cumulative absolute differences of the stage optimizer at consecutive stages The path length of the function list Path length grouping, defining the set Assume that the path length of all function lists is limited to L T , It is expressed by the formula:
[0101]
[0102] Among them, α is the preset interpolation coefficient. The shorter the path length, the better the performance of the online gradient descent algorithm.
[0103] For any function class and any set of lists of functions In online optimization problems involving switching costs, the dynamic regret upper bound of the online gradient descent algorithm is:
[0104]
[0105] in,
[0106] The update rule of the online gradient projection ascent algorithm can be expressed as follows:
[0107]
[0108] Among them, η t is the preset ascending step length, is the Euclidean projection of the parameter vector z on the feasible set Y, and ∥·∥ is the Euclidean normal form.
[0109] The dynamic regret upper bound of the online gradient projection ascent algorithm is:
[0110]
[0111] Where diam(y) represents the diameter of the feasible set Y, and L is the Lipschitz constant of the objective function gradient.
[0112] Step 105, perform a backoff update based on an online backoff prediction algorithm with a prediction window size of W, and finally obtain an optimal decision, and perform an edge computing network service cache update based on the obtained optimal decision.
[0113] In the specific implementation, in order to provide a more flexible caching strategy, the server performs backoff updates based on an online backoff prediction algorithm with a prediction window size of w, and finally obtains the optimal decision, and then updates the edge computing network service cache based on the optimal decision.
[0114] In one example, the server defines the prediction window size W, step size γ, learning rate η, and initializes x 0 , at time step s, use the output of the online gradient descent algorithm as the initial operation. Starting from time step s+W, gradually update the value of each time step forward. The update of each time step is based on the gradient information of the current time step and is adjusted based on the previous time step. It is expressed by the formula: in, represents the cache decision value calculated at time step s. For s = tW-1,…,t, x is updated once per step t , x t The update rule is: After W steps of backward prediction update, the optimal decision can be obtained.
[0115] This embodiment is particularly suitable for some delay-sensitive scenarios and resource-constrained application scenarios, such as real-time traffic information processing, real-time data analysis in medical health monitoring systems, real-time AR / VR data processing in games and entertainment, etc. Considering the switching cost of updating the cache strategy at different times, a cost model including the delay cost of processing the user arrival task in the current time slot and the switching cost of the change of the cache application set in the next time slot is proposed, which is more in line with the actual scenario. An edge collaborative network multi-time slot model is constructed, and the edge collaborative network is introduced to comprehensively consider the three processing methods of unloading tasks to the edge server, namely, direct processing at the edge, collaborative processing at the edge, and download processing from the cloud. Convex optimization is used when solving. By converting the discrete decision model into a continuous model, the convex optimization method is used to solve the optimal strategy, and combined with the dynamic regret evaluation method, the decision-making process is continuously optimized to improve system performance and service quality. An online backoff prediction algorithm based on the prediction window size W is used for backoff update, which can dynamically adapt to changes in task requests and cache requirements and provide a more flexible cache strategy.
[0116] The step division of the above methods is only for clear description. When implemented, they can be combined into one step or some steps can be split and decomposed into multiple steps. As long as they include the same logical relationship, they are all within the scope of protection of this application; adding insignificant modifications to the algorithm or process or introducing insignificant designs without changing the core design of the algorithm and process are all within the scope of protection of this application.
[0117] Another embodiment of the present application proposes an edge computing network service cache update system considering switching costs. The implementation details of the edge computing network service cache update system considering switching costs proposed in this embodiment are specifically described below. The following content is only for the convenience of understanding the implementation details provided, and is not necessary for implementing this example. Figure 5 This is a structural diagram of an edge computing network service cache update system considering switching costs proposed in this embodiment, including: a basic construction module 201, a cost model construction module 202, a convex optimization problem conversion module 203, a non-prediction module 204 and a backward update module 205.
[0118] The basic construction module 201 is used to build an edge collaborative network multi-slot model, define three processing methods for offloading tasks to edge servers, and dynamically update cache content in different time slots. The edge collaborative network multi-slot model is composed of several clients, several edge servers, a central controller and an edge collaborative network. The three processing methods are direct processing on the edge server side, collaborative processing on the edge server side, and downloading processing from the cloud.
[0119] The cost model building module 202 is used to build a cost model for the entire IoT system, wherein the cost of the entire IoT system includes the delay cost of processing the user arrival task in the current time slot and the switching cost of the cache application set change in the next time slot.
[0120] The convex optimization problem conversion module 203 is used to express the cache network strategy selection problem as an online convex optimization problem with a switching cost, and use dynamic regret as an evaluation indicator.
[0121] The non-prediction module 204 is used to achieve the minimum dynamic regret of the Internet of Things system by using the online gradient descent algorithm and the online gradient projection ascent algorithm under the condition of no prediction.
[0122] The backoff update module 205 is used to perform backoff update based on the online backoff prediction algorithm with a prediction window size of W, finally obtain the optimal decision, and perform edge computing network service cache update based on the obtained optimal decision.
[0123] It is worth mentioning that all modules involved in this embodiment are logic modules. In practical applications, a logic unit can be a physical unit, a part of a physical unit, or a combination of multiple physical units. In addition, in order to highlight the innovative part of this application, this embodiment does not introduce units that are not closely related to solving the technical problems proposed by this application, but this does not mean that there are no other units in this embodiment.
[0124] It is not difficult to find that this embodiment is a system embodiment corresponding to the above method embodiment, and this embodiment can be implemented in conjunction with the above method embodiment. The relevant technical details and technical effects mentioned in the above embodiments are still valid in this embodiment, and in order to reduce repetition, they are not repeated here. Accordingly, the relevant technical details mentioned in this embodiment can also be applied in the above embodiments.
[0125] Another embodiment of the present application provides an electronic device, whose specific structure is as follows: Figure 6 As shown, it includes: at least one processor 301; and a memory 302 that is communicatively connected to the at least one processor 301; wherein the memory 302 stores instructions that can be executed by the at least one processor 301, and the instructions are executed by the at least one processor 301 so that the at least one processor 301 can execute an edge computing network service cache update method that considers switching costs as described in the above embodiments.
[0126] Among them, the memory and the processor are connected in a bus manner, and the bus may include any number of interconnected buses and bridges, and the bus connects various circuits of one or more processors and memories together. The bus can also connect various other circuits such as peripheral devices, voltage regulators, and power management circuits, which are well known in the art and will not be further described in this article. The bus interface is responsible for providing an interface between the bus and the transceiver. The transceiver can be one component or multiple components, such as multiple receivers and transmitters, providing a unit for communicating with various other devices on a transmission medium. The data processed by the processor is transmitted on a wireless medium through an antenna, and further, the antenna also receives data and transmits the data to the processor.
[0127] The processor is responsible for managing the bus and general processing, and can also provide various functions, including timing, peripheral interfaces, voltage regulation, power management, and other control functions. Memory can be used to store data used by the processor when performing operations.
[0128] Another embodiment of the present application proposes a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it can implement an edge computing network service cache update method considering switching costs as described in the above embodiments.
[0129] That is, those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a program, and the program is stored in a storage medium, including a number of instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, ROM (Read-Only Memory), RAM (Random Access Memory), disk or optical disk and other media that can store program codes.
[0130] Those skilled in the art will appreciate that the above embodiments are specific embodiments for implementing the present application, and in actual applications, various changes may be made thereto in form and detail without departing from the spirit and scope of the present application.
Claims
1. A method for updating edge computing network service cache considering switching costs, characterized in that: include: Construct an edge collaborative network multi-slot model, define three processing methods for offloading tasks to edge servers, and dynamically update cache content in different time slots; the edge collaborative network multi-slot model consists of several clients, several edge servers, a central controller, and an edge collaborative network. The three processing methods are direct processing on the edge server, collaborative processing on the edge server, and downloading from the cloud. Construct a cost model for the entire IoT system; the cost of the entire IoT system includes the latency cost of processing the user arrival task in the current time slot and the switching cost of the cache application set change in the next time slot; The cache network strategy selection problem is formulated as an online convex optimization problem with switching cost, and dynamic regret is used as the evaluation metric. Under the condition of no prediction, the online gradient descent algorithm and the online gradient projection ascent algorithm are used to achieve the minimum dynamic regret of the Internet of Things system; The backoff update is performed based on the online backoff prediction algorithm with a prediction window size of W, and finally the optimal decision is obtained. The edge computing network service cache is updated based on the obtained optimal decision.
2. According to the edge computing network service cache update method considering switching costs according to claim 1, it is characterized in that: In the edge collaborative network multi-slot model, the client offloads the task to the nearby local edge server, and the local edge server provides services locally, that is, processing is directly performed on the edge server; If the local edge server does not cache the microservices required by the user, the corresponding task will be transferred to the nearby neighbor edge server that has cached the microservices required by the client. After the neighbor edge server completes the processing, it will feedback to the local edge server and the client, that is, edge server-side collaborative processing; if all neighbor edge servers do not cache the microservice set required by the client, the corresponding task will be sent to the cloud for processing, that is, download processing from the cloud; Define T as the working time of the edge server, define t as the update time of the edge server cache content, and define N t Represents the number of t in T, T / t=N t , define rf as the time for the edge server to process a single task offloaded by the client, which is the duration of 10 radio frames. It is assumed that the edge server associated with the client does not change in each radio frame. In different t, the client moves and the association relationship with the edge server changes; Suppose there are N edge servers in the edge collaboration network, where N is an integer greater than 1. Each edge server processes the client arrival tasks within T. The cache capacity of each edge server is M, where M is an integer greater than 1. The set of microservices cached by the i-th edge server is S i , s i = [s i1 , s i2 , …, s im , where m < M. The total set of microservices cached by the entire edge collaboration network is H im , H im = [s 11 , s 12 , …, s i1 , s i2 , …, s n1 , s n2 , …, s nm ; Assume that the edge server can only dynamically adjust the microservice set of its own cache at the beginning of each t according to the processing situation of the previous t, let x i,T =[X i,1 ,X i,2 ,…,X i,t ,…,X i,T ] is the cache decision of the ith edge server in the entire T, X i,t is the specific cache decision set of the i-th edge server at time t, X i,t =[x i,1,t ,x i,2,t ,…,x i,m,t ], each edge server hopes to select the optimal cache decision at each t to meet the Qos requirements of the client offloading task.
3. According to claim 2, a method for updating edge computing network service cache considering switching costs is characterized in that: Assuming that at time slot t, K tasks arrive and are offloaded to the edge server for processing, the latency cost of the entire IoT system at time slot t is expressed by the formula: Among them, D k (x t ) represents the latency cost of the entire IoT system in time slot t, local represents direct processing on the edge server, collaborate represents collaborative processing on the edge server, cloud represents downloading from the cloud, μ k represents the CPU cycles required to complete task k, f i represents the CPU frequency of the ith edge server, represents the uplink transmission time of task k, represents the time for the collaborative edge server to process task k, s k represents the data size of task k, r k represents the transmission speed of task k in the uplink, φ represents the sub-band bandwidth, P i represents the uplink transmission power of the edge server, h i represents the uplink channel gain between edge servers, N0 represents the noise power spectral density, represents the time required to upload task k to the cloud, represents the time it takes for the cloud to process task k, p(k,cl) represents the shortest path to upload to the cloud, and d c represents the latency of the cloud network link, cl k Indicates the maximum processing speed of the cloud.
4. According to the edge computing network service cache update method considering switching costs according to claim 3, it is characterized in that: The switching cost of the entire IoT system at time slot t is expressed by the formula: Among them, S(x t -x t-1 ) represents the switching cost of the entire IoT system at time slot t, x i,k,t and x i,k,t-1 They represent the caching decision of the i-th edge server for task k at time slot t and at time slot t-1, respectively.
5. According to the edge computing network service cache update method considering switching costs according to claim 4, it is characterized in that: The cost model of the entire IoT system is expressed by the formula: Among them, cost(T) represents the cost of the entire IoT system in time slot T; Dynamic regret is defined as the difference between the cost model of the entire IoT system and the given comparator sequence, which is expressed by the formula: Among them, Regret(u,T) represents dynamic regret.
6. The edge computing network service cache update method considering switching costs according to claim 5 is characterized in that: Under the condition of no prediction, the online gradient descent algorithm and the online gradient projection ascent algorithm are used to achieve the minimum dynamic regret of the IoT system, including: Using the online gradient descent algorithm, the action at each moment is updated by the following formula: in, is the preset descending step length, Is the cache strategy x t-1 The gradient at The cost function list is defined using the cumulative absolute difference of the stage optimizer in consecutive stages. The path length of the function list Path length grouping, defining the set Assume that the path length of all function lists is limited to L T , It is expressed by the formula: Among them, α is the preset interpolation coefficient. The shorter the path length, the better the performance of the online gradient descent algorithm. For any function class and any set of lists of functions In online optimization problems involving switching costs, the dynamic regret upper bound of the online gradient descent algorithm is: in, The update rule of the online gradient projection ascent algorithm is expressed by the formula: Among them, η t is the preset ascending step length, is the Euclidean projection of the parameter vector z on the feasible set Y, and ∥·∥ is the Euclidean normal form; The dynamic regret upper bound of the online gradient projection ascent algorithm is: Where diam(y) represents the diameter of the feasible set Y, and L is the Lipschitz constant of the objective function gradient.
7. A method for updating edge computing network service cache considering switching costs according to any one of claims 1 to 6, characterized in that: The backoff update is performed based on the online backoff prediction algorithm with a prediction window size of W, and the optimal decision is finally obtained, including: Define the prediction window size W, step size γ, learning rate η, and initialize x0; At time step s, use the output of the online gradient descent algorithm as the initial operation; Starting from time step s+W, the value of each time step is updated step by step. The update of each time step is based on the gradient information of the current time step and is adjusted based on the previous time step. It is expressed by the formula: in, represents the cache decision value calculated at time step s; For s = tW-1,…,t, update x once per step t , the update rule is: After W steps of backward prediction update, the optimal decision is obtained.
8. An edge computing network service cache update system considering switching costs, characterized in that: include: The basic building module is used to build an edge collaborative network multi-time slot model, define three processing methods for offloading tasks to edge servers, and dynamically update cache content in different time slots. The edge collaborative network multi-time slot model consists of several clients, several edge servers, a central controller, and an edge collaborative network. The three processing methods are direct processing on the edge server, collaborative processing on the edge server, and downloading from the cloud. The cost model building module is used to build the cost model of the entire IoT system, where the cost of the entire IoT system includes the delay cost of processing the user arrival task in the current time slot and the switching cost of the cache application set change in the next time slot; Convex optimization problem conversion module, which is used to formulate the cache network strategy selection problem as an online convex optimization problem with switching cost and uses dynamic regret as the evaluation indicator; The non-prediction module is used to achieve the minimum dynamic regret of the IoT system by using the online gradient descent algorithm and the online gradient projection ascent algorithm under the condition of no prediction; The backoff update module is used to perform backoff update based on the online backoff prediction algorithm with a prediction window size of W, and finally obtain the optimal decision, and update the edge computing network service cache based on the obtained optimal decision.
9. An electronic device, characterized in that: include: at least one processor; and, a memory communicatively coupled to the at least one processor; In which, the memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute an edge computing network service cache update method that considers switching costs as described in any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, it is possible to implement an edge computing network service cache update method considering switching costs as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Service caching and resource optimization method and system based on ADMM, medium and equipment
CN115696445A
Task unloading and service caching joint optimization method based on mobile edge computing
CN116233926A
Edge collaborative cache optimization method and device combined with resource allocation
CN116916390A
Short video sharing method and device based on edge assistance and storage medium
CN117425021A
Edge calculation admission control method under online task part predictable condition
CN117858107A