Cache method, device, storage medium, electronic device and program product
By determining the sub-content and cache status of the target task in the cloud-edge collaborative network and optimizing the cache strategy, the problem of content details being ignored and cache resources being wasted in the cloud-edge collaborative network is solved, and the utilization rate of cache resources is improved.
Patent Information
- Application Number
- CN202410574270.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-07
- Publication Date
- 2025-02-18
- Estimated Expiration
- 2044-05-07
AI Technical Summary
Cloud-edge collaborative networks tend to ignore the details of task content during processing, resulting in the processing results that cannot meet user needs, and storage in units of content will cause waste of cache resources.
By determining multiple subcontents corresponding to the target task, and determining the cache status of the subcontent at each network access point based on the characteristic information of the cloud-edge collaborative network, the target cache strategy is obtained, and the cache resource utilization in the cloud-edge collaborative network is optimized. .
It effectively avoids the problem of content details being ignored, improves the utilization rate of cache resources, and avoids the situation where smaller content occupies larger storage space.
Smart Images

Figure CN118714196B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of communication technology, and in particular, to a cache method, device, storage medium, electronic device and program product. Background Art
[0002] With the deepening trend of the Internet of Things and the continuous development of 5G and other network construction, the number of consumer and industrial Internet of Things devices will increase day by day. Most of the current smart Internet of Things devices send data to the cloud through the network, and the cloud performs unified processing. However, the wide access of smart terminals and the huge bandwidth occupied by massive sensory data during the transmission process, and the direct transmission of data to the cloud also increases the risk of privacy leakage. Only the coordination of cloud computing and edge computing (referred to as cloud-edge coordination) can meet the different needs of various application scenarios.
[0003] Cloud-edge collaboration uses content as the storage unit and caches the entire content or does not cache the entire content. Because cloud-edge collaboration only focuses on the storage of the entire content, it ignores the content details, resulting in the processing results of cloud-edge collaboration being unable to meet user needs. Moreover, when stored in content units, smaller content will occupy larger memory, resulting in a waste of cache resources. Summary of the invention
[0004] The purpose of the present disclosure is to provide a caching method, device, storage medium, electronic device and program product to improve the utilization rate of cache resources in a cloud-edge collaborative network while ensuring the details of the task content.
[0005] In order to achieve the above object, in a first aspect, the present disclosure provides a caching method, the method comprising:
[0006] Determine multiple sub-contents corresponding to the target task, and determine characteristic information of the cloud-edge collaborative network, the characteristic information including a maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network, and a cache capacity of each of the network access points;
[0007] Determine, according to the characteristic information, a cache status of the multiple sub-contents at each of the network access points, and obtain, according to the cache status, a target cache strategy of the multiple sub-contents in the cloud-edge collaborative network;
[0008] According to the target caching strategy, a plurality of the sub-contents are cached in the cloud-edge collaborative network.
[0009] In a second aspect, the present disclosure provides a cache device, the device comprising:
[0010] A content segmentation module, used to determine multiple sub-contents corresponding to the target task, and determine characteristic information of the cloud-edge collaborative network, wherein the characteristic information includes a maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network, and a cache capacity of each of the network access points;
[0011] an execution module, configured to determine, according to the characteristic information, a cache status of the plurality of sub-contents at each of the network access points, and obtain, according to the cache status, a target cache strategy of the plurality of sub-contents in the cloud-edge collaborative network;
[0012] A control module is used to cache the multiple sub-contents in the cloud-edge collaborative network according to the target caching strategy.
[0013] In a third aspect, the present disclosure provides a non-temporary computer-readable storage medium having a computer program stored thereon, which implements the method described in the first aspect when executed by a processor.
[0014] In a fourth aspect, the present disclosure provides an electronic device, including:
[0015] a memory having a computer program stored thereon;
[0016] A processor is used to execute the computer program in the memory to implement the method described in the first aspect.
[0017] In a fifth aspect, the present disclosure provides a computer program product, comprising computer program instructions, which will only implement the method described in the first aspect when executed by a processor.
[0018] Through the above technical solution, multiple sub-contents corresponding to the target task are missing, so that the content details of the target task are not ignored during the processing of the cloud-edge collaborative network; the cache status of multiple sub-contents at each network access point is determined according to the characteristic information of the cloud-edge collaborative network, and the target cache strategy of multiple sub-contents in the cloud-edge collaborative network is obtained according to the cache status. According to the target cache strategy, multiple sub-contents are cached in the cloud-edge collaborative network to avoid smaller content occupying larger storage space, thereby improving the utilization rate of cache resources in the cloud-edge collaborative network.
[0019] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The accompanying drawings are used to provide a further understanding of the present disclosure and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the present disclosure but do not constitute a limitation of the present disclosure. In the accompanying drawings:
[0021] Figure 1The figure is a flowchart of a caching method according to an exemplary embodiment of the present disclosure.
[0022] Figure 2 A topology structure of a cloud-edge collaborative network is shown according to an exemplary embodiment of the present disclosure.
[0023] Figure 3 is another flow chart of a caching method according to an exemplary embodiment of the present disclosure.
[0024] Figure 4a 4 is a comparison diagram of cache capacity between a cache method and an LRFU method according to an exemplary embodiment of the present disclosure.
[0025] Figure 4b 4 is a comparison diagram of content popularity between a caching method and an LRFU method according to an exemplary embodiment of the present disclosure.
[0026] Figure 5 is a block diagram showing a cache device according to an exemplary embodiment of the present disclosure.
[0027] Figure 6 is a block diagram of an electronic device according to an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION
[0028] The specific implementation of the present disclosure is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described herein is only used to illustrate and explain the present disclosure, and is not used to limit the present disclosure.
[0029] It should be noted that all actions of acquiring signals, information or data in the present disclosure are carried out in compliance with the relevant data protection laws and policies of the country where the device is located and with the authorization given by the owner of the corresponding device.
[0030] As mentioned in the background technology, with the rapid development of Internet of Things technology, the number of Internet users has exploded. The substantial growth in the number of Internet users is accompanied by the need to improve the quality of network services, which poses a huge challenge to edge networks with limited cache capacity and computing power. In order to solve the above challenges, cloud computing came into being. Cloud computing allows users to selectively transmit their requests to service centers for processing. The flexibility of cloud resources enables content providers to build and expand content distribution systems through cloud servers, and reduce the network burden by transferring computing or storage tasks to cloud computing centers with powerful computing and storage capabilities. However, because the distance between the cloud computing center and the user end may cause serious data transmission delays, and the traffic of data converged to the cloud computing center may cause the core network to be overwhelmed, so by deploying servers with cache and computing capabilities on the edge access network, user requests are transferred to devices closer to the edge for processing, thereby effectively reducing network congestion and meeting users' requirements for low-latency network quality of service (QoS), that is, the concept of edge computing. The widespread access of smart terminals and the huge bandwidth occupied by massive sensory data during transmission also increase the risk of privacy leakage when data is directly transmitted to the cloud. Only cloud-edge collaboration can meet the different needs of various application scenarios.
[0031] The inventors found that because cloud-edge collaboration uses content as the storage unit, caching the entire content or not caching the entire content. It only focuses on the storage of the entire content, thus ignoring the content details, resulting in the processing results of cloud-edge collaboration may not meet user needs, and storage based on content as a unit will result in a situation where small content occupies a large amount of memory, resulting in a waste of cache resources.
[0032] In view of this, the present disclosure provides a caching method, device, storage medium, electronic device and program product, which improve the utilization rate of cache resources in a cloud-edge collaborative network while ensuring the details of the task content.
[0033] Figure 1 is a flowchart of a caching method according to an exemplary embodiment of the present disclosure. Figure 1 As shown, the caching method may include the following steps:
[0034] In step S11, multiple sub-contents corresponding to the target task are determined, and characteristic information of the cloud-edge collaborative network is determined, the characteristic information including the maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network, and the cache capacity of each network access point.
[0035] It is worth noting that in the embodiments of the present disclosure, the cloud-edge collaborative network can be a three-layer topology structure consisting of 1 cloud, N network access points and M user terminals. Figure 2As shown, the cloud-edge collaborative network includes 1 cloud 110, 3 network access points (130, 131 and 132) and 6 user terminals (120, 121, 122, 123, 124 and 125). Each network access point carries a part of users through an orthogonal frequency division multiplexing wireless channel. The network access point and the user terminal can transmit content through a wireless link, that is, each network access point covers one or more user terminals, such as network access point 130 covers user terminals 120 and user terminals 121. There is a communication connection between the cloud and each network access point, such as a communication link 152 between cloud 110 and network access point 130, a communication link 151 between cloud 110 and network access point 131, and a communication link 150 between cloud 110 and network access point 132. There are communication links between network access points, and content can be transmitted between network access points through limited links. For example, there is a communication link 160 between network access point 130 and network access point 131, and there is a communication link 161 between network access point 131 and network access point 132. Each network access point is equipped with a cache, for example, network access point 130 is equipped with a cache 140, network access point 131 is equipped with a cache 141, and network access point 132 is equipped with a cache 142.
[0036] It should be understood that both the network access points and the cloud in the cloud-edge collaborative network can process target tasks, thereby improving the caching and computing capabilities of the cloud-edge collaborative network. The network access points can only cache part of the target task content corresponding to the target tasks sent by the user end on which they are mounted, while the cloud can cache the target task content corresponding to the target tasks sent by all users.
[0037] In step S12, the cache status of the multiple sub-contents at each network access point is determined according to the characteristic information, and the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network is obtained according to the cache status.
[0038] It is worth mentioning that, based on the feature information, the caching problem of multiple sub-contents in the cloud-edge collaborative network is decomposed into the caching problem of multiple sub-contents at each network access point, and the caching problem of each network access point is solved in parallel, thereby realizing the dual decomposition (Dual Decomposition, DD) of the caching problem of multiple contents in the cloud-edge collaborative network. The complex problem is simplified, and the caching problem of each network access point is solved in parallel, so as to obtain the optimal caching method of multiple sub-contents in the cloud-edge collaborative network faster and more effectively, thereby shortening the caching time, that is, the target caching strategy.
[0039] In step S13, multiple sub-contents are cached in the cloud-edge collaborative network according to the target caching strategy.
[0040] In the disclosed embodiments, by determining the multiple sub-contents corresponding to the target task, the content details of the target task are avoided from being ignored during the cloud-edge collaborative network processing; by determining the cache status of the multiple sub-contents at each network access point according to the characteristic information of the cloud-edge collaborative network, and according to the cache status, the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network is obtained; that is, by splitting the cache problem of the target task content in the cloud-edge collaborative network into the cache problem of the target task content in each network access point, the optimal cache method is obtained. According to the target cache strategy, multiple sub-contents are cached in the cloud-edge collaborative network to avoid smaller content occupying a larger storage space, thereby improving the utilization rate of cache resources in the cloud-edge collaborative network.
[0041] In order to facilitate those skilled in the art to better understand the caching method provided by the present disclosure, the steps of the caching method are described in detail below.
[0042] In a feasible implementation, the target task can be determined by:
[0043] In response to a user operation of a target user terminal, a target task corresponding to the user operation is generated, and task content corresponding to the target task is divided to obtain a plurality of sub-contents; or
[0044] In response to the user operation of the target user terminal, a target task corresponding to the user operation is generated, and the target task is divided into tasks according to the task type to obtain multiple subtasks, each of which corresponds to a sub-content.
[0045] It is worth noting that the task content of the target task can be equally divided into multiple sub-contents according to a preset segmentation ratio, and the size of each sub-content segment is the same. Among them, the preset segmentation ratio can be preset according to the size of the cache space in the cloud-edge collaborative network, and can also be preset according to the content characteristics of the task content. For example, in the case where the target task is to download a target video, the target task content is video content, and the video content is divided into multiple video content segments of the same content size according to the preset segmentation ratio.
[0046] It should be understood that the performance gap between the task splitting and non-task splitting schemes may increase with the increase of content popularity, and may also decrease with the increase of the request hit rate of the target task. Therefore, in the embodiment of the present disclosure, the target task generated according to the user operation can be split into multiple subtasks, so as to ensure the popularity of the content during the caching process.
[0047] For example, in the task segmentation scheme, according to the task type The target task c is split into multiple independent subtasks, and the task set corresponding to the target task is , target task , that is, all subtasks constitute a complete target task. Among them, the task type , represents a subset of task types, and The sum of the data volume of all subtasks is the data volume of the target task to which they belong. Characterize the amount of data corresponding to the target task c, Representation subtask The amount of data.
[0048] In a feasible implementation manner, in step S12, determining the cache status of the plurality of sub-contents at each network access point according to the characteristic information may include:
[0049] For each network access point, the cache state of each sub-content at the network access point is determined according to the characteristic information and preset constraints of the network access point, where the preset constraints are used to constrain the cache capacity and cache content of the network access point, as well as the total delay between the target user terminal and the network access point.
[0050] It is worth noting that the preset constraint conditions can be preset according to the optimization problem. In the embodiment of the present disclosure, four constraint conditions are preset according to the optimization problem: , , as well as , each constraint is as follows:
[0051] , used to constrain network access points The amount of data cached in the network cannot exceed the network access point The cache capacity of Characterize the network access point, N B Characterize the network access point set, D i Characterizing Network Access Points The cache capacity.
[0052] , used to constrain network access points Efficient use of cache capacity, such as network access points Neighboring network access points The cache contents are different between . Characterize the user side, Characterizing Network Access Points The set of clients to cover.
[0053] , used to constrain the target user end With network access point The total delay between is less than the maximum waiting time between the user terminal and the network access point. Characterize the target user With network access point The total delay between Indicates the maximum waiting time between the user terminal and the network access point.
[0054] , used to constrain network access points About the target task The cache status of the network access point can ensure QoS. Whether to cache the target task The corresponding content, Characterizing Network Access Points Target task has been cached The corresponding content, Characterizing Network Access Points Target task not cached The corresponding content.
[0055] It is worth noting that the optimization problem in the embodiments of the present disclosure may be to optimize the total delay between the user terminal and the network access point, that is, .
[0056] In the disclosed embodiments, the caching problem of the target task content in the cloud-edge collaborative network is dually decomposed to obtain multiple sub-problems of the caching method of all sub-contents in each network access point, and the complex caching problem is simplified to simplify the calculation process and reduce the amount of calculation, so as to obtain the optimal caching method of the target task content in the cloud-edge collaborative network faster and more effectively.
[0057] In a feasible implementation manner, determining the cache status of each sub-content at the network access point according to the characteristic information and the preset constraint condition of the network access point may include:
[0058] According to the characteristic information and the preset constraints of the network access point, a Lagrangian function corresponding to the network access point is constructed, and the Lagrangian operator in the Lagrangian function is determined according to the original problem, which is to minimize the total delay between the target user terminal and the network access point;
[0059] Convert the original problem into a dual problem, and decompose the dual problem to obtain multiple sub-problems corresponding to each sub-content;
[0060] For each subproblem corresponding to the same subcontent, the Lagrangian function is converted into the dual function of the corresponding subproblem, and the dual variable in the dual function is updated. The dual function is iteratively solved until the total delay between the target user terminal and the network access point is minimized, and the cache status of the subcontent in the network access point is obtained.
[0061] For example, take a network access point For example, taking minimizing the total delay between the target user terminal and the network access point as the original problem, the constraints are determined and preset respectively. Related variables , and preset constraints Variables And with the preset constraints Related variables , because the original problem is not strictly convex, a regularization term is added, and the corresponding network access point is constructed in combination with the proximal regularization term The Lagrangian function of :
[0062] ;
[0063] in, Characterize additional variables, Characterizes a positive scalar.
[0064] Convert the original problem to a dual problem ,in, , , . And decompose the dual problem to obtain multiple sub-problems .
[0065] For each sub-problem corresponding to the same sub-content, three preset constraints are used , , Corresponding variables , and As the dual variable, transform the Lagrangian function into the dual function of the corresponding subproblem:
[0066] .
[0067] The dual variables are updated by the subgradient method, and the dual function is iteratively solved. For example, in the (t+1)th iteration, the process of updating the dual variables may include:
[0068] ;
[0069] ;
[0070] ;
[0071] in, Characterization The optimal value of the original variable solved by the iteration, Characterization At iteration The step length, Characterization At iteration The step length, Characterization At iteration The step length of , where t o Characterizes the amount of data corresponding to the initial content.
[0072] According to the dual function corresponding to each sub-problem, it can be determined that when When is fixed, the dual function can be guaranteed to be strictly convex, that is, and The minimum alternation can be achieved, so the iterative solution process of the dual function is equivalent to continuously punishing the previous calculation results, so as to ensure that the link state gradually approaches the optimal, that is, when the total delay between the target user terminal and the network access point reaches the minimum.
[0073] Specifically, in use replace When , the dual function transforms into:
[0074]
[0075]
[0076] .
[0077] because is relaxed to a continuous variable between [0, 1], so it is necessary to solve the dual function to obtain Perform relaxation recovery to make it a binary variable in {0, 1}. The specific process of relaxation recovery may include:
[0078] .
[0079] Minimize the total delay between the target user terminal and the network access point As sub-content in the network access point The cache status.
[0080] The dual decomposition process may include the following steps:
[0081] Initialization process;
[0082] Set the number of iterations =1;
[0083] Set the original variable initial value ;
[0084] Set the initial value of the dual variable , , ;
[0085] Repeat
[0086] For =1→ N B do
[0087] For =1→ N μ,i Ndo
[0088] For c =1→ do
[0089] For c k =1→ do
[0090] Solving the dual function , and relax the calculation results to obtain ;
[0091] End
[0092] End
[0093] End
[0094] End
[0095] For =1→ N B do
[0096] For =1→ N μ,i do
[0097] For c =1→ do
[0098] For c k =1→ do
[0099] Update the dual variables through the subgradient method, , , ;
[0100] End
[0101] End
[0102] End
[0103] End
[0104] renew ;
[0105] renew ;
[0106] renew ;
[0107] Until converge;
[0108] Result .
[0109] In the implementation manner of the present disclosure, the optimal caching method is determined in a cloud-edge collaborative environment based on content popularity and cache capacity, with the starting point of reducing network content transmission latency. The entire process is edge-computing through a distributed algorithm, and all optimization variables are processed by the corresponding nodes. Compared with the existing cloud-edge collaborative resource allocation model based on task partitioning, there is no need to send the status of each node in the network, the status of each link, and information to a specific node for comparison. The present disclosure aims to minimize latency and uses a low-complexity algorithm based on dual decomposition to address dynamic caching strategy issues.
[0110] In a feasible implementation manner, the total delay between the target user terminal and the network access point can be obtained by:
[0111] Determine the transmission delay between the network access point and the target user terminal, and determine the service delay of the network access point in processing the target task;
[0112] According to the transmission delay and service delay, the total delay between the target user terminal and the network access point is obtained.
[0113] For example, in a cloud-edge collaborative network, in a scenario where task segmentation and content segmentation are performed simultaneously, in response to a user operation at a target user end, a task c corresponding to the user operation is generated, and task c is segmented according to the task type to obtain multiple target tasks. . Network access point With the user end The transmission delay between , network access point The service delay for processing task c is T i S , user side Upload task c to the network access point , until the total delay of getting the returned data T ij c , the total delay represents all target tasks of task c at the same time Processed simultaneously, the maximum delay incurred by all processes:
[0114] ,
[0115] in, Characterize when the network access point Unable to process target task When Pass to the network access point Neighboring network access points Delay in processing.
[0116] In a feasible implementation manner, determining the transmission delay between the network access point and the target user terminal may include:
[0117] Determine a first transmission delay for the network access point to send the target task to the target user terminal, and a second transmission delay for the target user terminal to send the target task to the network access point;
[0118] The sum of the first transmission delay and the second transmission delay is used as the transmission delay between the network access point and the target user terminal.
[0119] It should be understood that the transmission delay is affected by the transmission data rate between the network access point and the user end, and the transmission data rate can be determined according to the signal-to-noise ratio between the network access point and the user end.
[0120] For example, determining the user end Assigned to the network access point The response signal-to-interference-noise ratio experienced when:
[0121] ,
[0122] in, Characterizing the User End Assigned to the network access point The signal-to-noise ratio, P ij Characterize the access point from the network To the user The power distribution, Characterizing Network Access Points The maximum transmit power of satisfy , thereby limiting network access points The transmission power provided to all its users shall not exceed its maximum power. Characterizes the channel gain, Characterizes the variance of additive white Gaussian noise, Characterizes the interference caused by other network access points and their user end downlink transmission.
[0123] Accordingly, the network access point To the user The transmission data rate when sending the target task is:
[0124] ;
[0125] in, Characterizing Network Access Points To the user The rate at which bits are transmitted per second.
[0126] Similarly, determine the network access point The corresponding signal-to-interference-noise ratio experienced is:
[0127] ,
[0128] in, Characterizing Network Access Points The corresponding signal-to-noise ratio experienced, P ji Characterizes the channel gain, P j max Characterizing the User End The maximum generated power, and P j max satisfy , in order to limit the transmission power of the user end when sending a request to the network access point to not exceed the maximum power, Characterization from the user side To the network access point The power distribution, Characterizes the interference caused by other user terminals transmitting to the network access point.
[0129] Accordingly, the user side Send the target task to the network access point The transmission data rate is:
[0130] ;
[0131] in, Characterizing the User End Access Point The rate at which bits are transmitted per second.
[0132] It is worth noting that since the uplink and downlink transmissions between the user end and the network access point need to meet the requirements of high data rates, is preset to and ,in, Characterizes each uplink transmission between the user end and the network access point The minimum value of Characterizes each downlink transmission between the user end and the network access point The minimum value of .
[0133] For example, determine the network access point To the target user Send target task The first transmission delay , and the target user Access Point Send target task The second transmission delay , network access point Target client The transmission delay between them is:
[0134] .
[0135] In a feasible implementation manner, determining the service delay of the network access point in processing the target task may include:
[0136] Determine the queuing delay of the target task when the network access point processes the target task, and determine the computational delay of the network access point processing the target task;
[0137] The sum of the queuing delay and the computational delay is taken as the transmission delay of the network access point for processing the target task.
[0138] It is worth noting that the rate at which the user terminal at the network access point sends tasks is constantly changing, so the service rate is continuously changing. It is necessary to determine the average stay time of the network access point for each target task based on the queuing theory, that is, the service delay. The service delay may include the average queuing delay and the average service delay of the network access point for each target task.
[0139] For example, assume that each network access point in the cloud-edge collaborative network has the same service capability, and the process of satisfying requests by the network access point is modeled as an M / M / a / N queuing system, where a represents the number of servers, such as the number of network access points. The number of servers with α i Indicates; N indicates the finite queue length, such as the network access point The length of the user request task queue is A; at the same time, the arrival rate of the target task is λ i , network access point The service rate is μ i , then the network access point Utilization rate ρ i for:
[0140] .
[0141] According to queuing theory, network access points The service delay for each target task T i s for:
[0142] ;
[0143] in, Characterizes the average queuing delay, q i Characterizing Network Access Points The queue length, P N,i Characterizing Network Access Points The probability that the number of target tasks reaches the capacity of its queue, Characterizes the average computational delay, , Characterizing Network Access Points The average number of CPU (Central Processing Unit) revolutions required to process a target task, v i Characterizing Network Access Points The average CPU speed required to process a target task.
[0144] The following is a complete example to illustrate the caching method provided by the present disclosure. Figure 3 As shown, the caching method may include the following steps:
[0145] In step S31, in response to the user operation of the target user terminal, a target task c corresponding to the user operation is generated, and the target task c is divided into multiple subtasks according to the task type. , each subtask corresponds to a sub-content.
[0146] In step S32, characteristic information of the cloud-edge collaborative network is determined, and the characteristic information includes the maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network. , and the cache capacity of each network access point.
[0147] In step S33, the cache status of the multiple sub-contents at each network access point is determined according to the characteristic information, and the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network is obtained according to the cache status.
[0148] In step S34, multiple sub-contents are cached in the cloud-edge collaborative network according to the target cache strategy.
[0149] According to the node parameters shown in Table 1, the caching method provided by the present disclosure is compared with the influence of the LRFU (Least Recently / Frequently Used, LRFU, least recently used / frequently used algorithm) on the latency under different cache capacities, and the following results can be obtained: Figure 4a The network latency status is shown.
[0150] Table 1
[0151]
[0152] like Figure 4a As shown in the figure, Task representation does not perform task segmentation, while SubTask representation performs task segmentation. When the cache size increases, the edge node can store more popular content, which is conducive to timely response to user requests, and the request latency is reduced accordingly. Comparing the results, as the request hit rate increases with the increase of cache size, the performance gap between task segmentation and non-task segmentation also increases. That is, when the cache capacity of the network access point increases, the results of all schemes will be improved.
[0153] Similarly, according to the node parameters shown in Table 2, the caching method provided by the present disclosure is compared with the LRFU (Least Recently / Frequently Used, LRFU, least recently used / frequently used algorithm) algorithm under different content popularity to analyze the impact of latency, and the following results can be obtained: Figure 4b The network latency status is shown.
[0154] Table 2
[0155]
[0156] like Figure 4b As shown in the figure, when the popularity of the content increases, the user's task request is more inclined to request popular content, so that the cache of the edge node is sufficient to meet the user's task request. Comparing the results, the performance gap between task splitting and not task splitting increases with the increase of content popularity, and decreases with the increase of request hit rate. Figure 4a and Figure 4bThe horizontal axis in is the ratio of the maximum number of contents that a node can cache to the total number of content types in the network.
[0157] Based on the same inventive concept, the present disclosure further provides a cache device, which includes a content segmentation module 501 , an execution module 502 and a control module 503 .
[0158] Among them, the content segmentation module 501 is used to determine multiple sub-contents corresponding to the target task and determine the characteristic information of the cloud-edge collaborative network, the characteristic information including the maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network, and the cache capacity of each network access point.
[0159] The execution module 502 is used to determine the cache status of the multiple sub-contents at each network access point according to the characteristic information, and obtain the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network according to the cache status.
[0160] The control module 503 is used to cache multiple sub-contents in the cloud-edge collaborative network according to the target caching strategy.
[0161] In the disclosed embodiments, by determining the multiple sub-contents corresponding to the target task, the content details of the target task are avoided from being ignored during the cloud-edge collaborative network processing; by determining the cache status of the multiple sub-contents at each network access point according to the characteristic information of the cloud-edge collaborative network, and according to the cache status, the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network is obtained; that is, by splitting the cache problem of the target task content in the cloud-edge collaborative network into the cache problem of the target task content in each network access point, the optimal cache method is obtained. According to the target cache strategy, multiple sub-contents are cached in the cloud-edge collaborative network to avoid smaller content occupying a larger storage space, thereby improving the utilization rate of cache resources in the cloud-edge collaborative network.
[0162] In a feasible implementation, the content segmentation module 501 is used to generate a target task corresponding to the user operation in response to the user operation of the target user terminal, and to segment the task content corresponding to the target task to obtain multiple sub-contents; or
[0163] In response to the user operation of the target user terminal, a target task corresponding to the user operation is generated, and the target task is divided into tasks according to the task type to obtain multiple subtasks, each of which corresponds to a sub-content.
[0164] In a feasible implementation manner, the execution module 502 is used to determine, for each network access point, a cache state of each sub-content at the network access point according to the characteristic information and a preset constraint condition of the network access point, where the preset constraint condition is used to constrain the cache capacity and cache content of the network access point, and the total delay between the target user terminal and the network access point.
[0165] In a feasible implementation manner, the execution module 502 is used to construct a Lagrangian function corresponding to the network access point according to the characteristic information and the preset constraints of the network access point, and the Lagrangian operator in the Lagrangian function is determined according to the original problem, and the original problem is to minimize the total delay between the target user terminal and the network access point;
[0166] Convert the original problem into a dual problem, and decompose the dual problem to obtain multiple sub-problems corresponding to each sub-content;
[0167] For each subproblem corresponding to the same subcontent, the Lagrangian function is converted into the dual function of the corresponding subproblem, and the dual variable in the dual function is updated. The dual function is iteratively solved until the total delay between the target user terminal and the network access point is minimized, and the cache status of the subcontent in the network access point is obtained.
[0168] In a feasible implementation, the execution module 502 is used to determine the transmission delay between the network access point and the target user terminal, and determine the service delay of the network access point in processing the target task;
[0169] According to the transmission delay and service delay, the total delay between the target user terminal and the network access point is obtained.
[0170] In a feasible implementation, the execution module 502 is used to determine a first transmission delay for the network access point to send the target task to the target user terminal, and a second transmission delay for the target user terminal to send the target task to the network access point;
[0171] The sum of the first transmission delay and the second transmission delay is used as the transmission delay between the network access point and the target user terminal.
[0172] In a feasible implementation, the execution module 502 is used to determine the queuing delay of the target task when the network access point processes the target task, and determine the calculation delay of the network access point processing the target task;
[0173] The sum of the queuing delay and the computational delay is taken as the transmission delay of the network access point for processing the target task.
[0174] Regarding the cache device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0175] Based on the same inventive concept, the present disclosure also provides an electronic device, including:
[0176] a memory having a computer program stored thereon;
[0177] The processor is used to execute the computer program in the memory to implement the above-mentioned cache method.
[0178] In the disclosed embodiments, by determining the multiple sub-contents corresponding to the target task, the content details of the target task are avoided from being ignored during the cloud-edge collaborative network processing; by determining the cache status of the multiple sub-contents at each network access point according to the characteristic information of the cloud-edge collaborative network, and according to the cache status, the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network is obtained; that is, by splitting the cache problem of the target task content in the cloud-edge collaborative network into the cache problem of the target task content in each network access point, the optimal cache method is obtained. According to the target cache strategy, multiple sub-contents are cached in the cloud-edge collaborative network to avoid smaller content occupying a larger storage space, thereby improving the utilization rate of cache resources in the cloud-edge collaborative network.
[0179] Figure 6 FIG. 6 is a block diagram of an electronic device 600 according to an exemplary embodiment. Figure 6 As shown, the electronic device 600 may include: a processor 601 , a memory 602 . The electronic device 600 may also include one or more of a multimedia component 603 , an input / output (I / O) interface 604 , and a communication component 605 .
[0180] The processor 601 is used to control the overall operation of the electronic device 600 to complete all or part of the steps in the above-mentioned caching method. The memory 602 is used to store various types of data to support the operation of the electronic device 600. For example, these data may include instructions for any application or method used to operate on the electronic device 600, and application-related data, such as contact data, sent and received messages, pictures, audio, video, etc. The memory 602 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (Static Random Access Memory, referred to as SRAM), electrically erasable programmable read-only memory (Electrically Erasable Programmable Read-Only Memory, referred to as EEPROM), erasable programmable read-only memory (Erasable Programmable Read-Only Memory, referred to as EPROM), programmable read-only memory (Programmable Read-Only Memory, referred to as PROM), read-only memory (Read-Only Memory, referred to as ROM), magnetic memory, flash memory, magnetic disk or optical disk. The multimedia component 603 may include a screen and an audio component. The screen may be, for example, a touch screen, and the audio component is used to output and / or input audio signals. For example, the audio component may include a microphone for receiving external audio signals. The received audio signal may be further stored in the memory 602 or sent through the communication component 605. The audio component also includes at least one speaker for outputting audio signals. The I / O interface 604 provides an interface between the processor 601 and other interface modules, and the above-mentioned other interface modules may be keyboards, mice, buttons, etc. These buttons may be virtual buttons or physical buttons. The communication component 605 is used for wired or wireless communication between the electronic device 600 and other devices. Wireless communication, such as Wi-Fi, Bluetooth, Near Field Communication (NFC), 2G, 3G, 4G, NB-IOT, eMTC, or other 5G, etc., or a combination of one or more of them, is not limited here. Therefore, the corresponding communication component 605 may include: Wi-Fi module, Bluetooth module, NFC module, etc.
[0181] In an exemplary embodiment, the electronic device 600 can be implemented by one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), controllers, microcontrollers, microprocessors or other electronic components to execute the above-mentioned caching method.
[0182] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by a processor, the steps of the above-mentioned caching method are implemented. For example, the computer-readable storage medium can be the above-mentioned memory 602 including program instructions, and the above-mentioned program instructions can be executed by the processor 601 of the electronic device 600 to complete the above-mentioned caching method.
[0183] In another exemplary embodiment, a computer program product is further provided. The computer program product includes a computer program executable by a programmable device. The computer program has a code portion for executing the above caching method when executed by the programmable device.
[0184] The preferred embodiments of the present disclosure are described in detail above in conjunction with the accompanying drawings; however, the present disclosure is not limited to the specific details in the above embodiments. Within the technical concept of the present disclosure, a variety of simple modifications can be made to the technical solution of the present disclosure, and these simple modifications all fall within the protection scope of the present disclosure.
[0185] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present disclosure will not further describe various possible combinations.
[0186] In addition, various embodiments of the present disclosure may be arbitrarily combined, and as long as they do not violate the concept of the present disclosure, they should also be regarded as the contents disclosed by the present disclosure.
Claims
1. A caching method, characterized in that: The method comprises: Determine multiple sub-contents corresponding to the target task, and determine characteristic information of the cloud-edge collaborative network, the characteristic information including a maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network, and a cache capacity of each of the network access points; Determine, according to the characteristic information, a cache status of the multiple sub-contents at each of the network access points, and obtain, according to the cache status, a target cache strategy of the multiple sub-contents in the cloud-edge collaborative network; caching a plurality of the sub-contents in the cloud-edge collaborative network according to the target caching strategy; The determining, according to the characteristic information, a cache status of the plurality of sub-contents at each of the network access points comprises: For each of the network access points, determining a cache state of each of the sub-contents at the network access point according to the characteristic information and a preset constraint condition of the network access point, wherein the preset constraint condition is used to constrain a cache capacity and cache content of the network access point, and a total delay between the target user terminal and the network access point; The determining, according to the characteristic information and the preset constraint condition of the network access point, a cache status of each sub-content at the network access point includes: Constructing a Lagrangian function corresponding to the network access point according to the characteristic information and preset constraints of the network access point, wherein a Lagrangian operator in the Lagrangian function is determined according to an original problem, wherein the original problem is to minimize a total delay between the target user terminal and the network access point; Convert the original problem into a dual problem, and decompose the dual problem to obtain multiple sub-problems corresponding to each of the sub-contents; For each of the sub-problems corresponding to the same sub-content, the Lagrangian function is converted into a dual function corresponding to the sub-problem, and the dual variable in the dual function is updated, and the dual function is iteratively solved until the total delay between the target user terminal and the network access point is minimized, and the cache state of the sub-content in the network access point is obtained.
2. The caching method according to claim 1, characterized in that: The target task is determined by: In response to a user operation of a target user terminal, a target task corresponding to the user operation is generated, and task content corresponding to the target task is divided into multiple sub-contents; or, In response to a user operation of a target user terminal, a target task corresponding to the user operation is generated, and the target task is segmented according to the task type to obtain a plurality of subtasks, each of which corresponds to a sub-content.
3. The caching method according to claim 1, characterized in that: The total delay between the target user terminal and the network access point is obtained by: Determining a transmission delay between the network access point and the target user terminal, and determining a service delay for the network access point to process the target task; A total delay between the target user terminal and the network access point is obtained according to the transmission delay and the service delay.
4. The caching method according to claim 3, characterized in that: The determining of the transmission delay between the network access point and the target user terminal includes: Determining a first transmission delay for the network access point to send the target task to the target client, and a second transmission delay for the target client to send the target task to the network access point; The sum of the first transmission delay and the second transmission delay is used as the transmission delay between the network access point and the target user terminal.
5. The caching method according to claim 4, characterized in that: The determining the service delay of the network access point in processing the target task includes: Determine a queuing delay of the target task when the network access point processes the target task, and determine a computational delay of the network access point processing the target task; The sum of the queuing delay and the calculation delay is used as the transmission delay of the network access point in processing the target task.
6. A cache device, characterized in that: The device comprises: A content segmentation module, used to determine multiple sub-contents corresponding to the target task, and determine characteristic information of the cloud-edge collaborative network, wherein the characteristic information includes a maximum waiting time between the target user terminal and each network access point in the cloud-edge collaborative network, and a cache capacity of each of the network access points; The execution module is used to determine the cache status of the multiple sub-contents at each of the network access points according to the characteristic information, and obtain the target cache strategy of the multiple sub-contents in the cloud-edge collaborative network according to the cache status; for each network access point, determine the cache status of each sub-content at the network access point according to the characteristic information and the preset constraint conditions of the network access point, the preset constraint conditions are used to constrain the cache capacity and cache content of the network access point, and the total delay between the target user terminal and the network access point; construct the corresponding network access point according to the characteristic information and the preset constraint conditions of the network access point The Lagrangian function of the point, the Lagrangian operator in the Lagrangian function is determined according to the original problem, the original problem is to minimize the total delay between the target user terminal and the network access point; the original problem is converted into a dual problem, and the dual problem is decomposed to obtain multiple sub-problems corresponding to each sub-content; for each sub-problem corresponding to the same sub-content, the Lagrangian function is converted into a dual function of the corresponding sub-problem, and the dual variable in the dual function is updated, and the dual function is iteratively solved until the total delay between the target user terminal and the network access point is minimized, and the cache status of the sub-content in the network access point is obtained; A control module is used to cache the multiple sub-contents in the cloud-edge collaborative network according to the target caching strategy.
7. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 5 is implemented.
8. An electronic device, characterized in that: include: a memory having a computer program stored thereon; A processor, configured to execute the computer program in the memory to implement the method according to any one of claims 1 to 5.
9. A computer program product comprising computer program instructions, characterized in that The computer program will only implement the method according to any one of claims 1 to 5 when executed by a processor.
Citation Information
Patent Citations
Time delay optimal caching and routing method, device and system based on cloud edge collaboration
CN114205782A