Resource preheating method and related device
By acquiring and utilizing the preheating node information of the target resources, and responding to the preheating request only to the appropriate CDN node, the waste of bandwidth and storage resources in the existing CDN preheating mechanism is solved, improving the preheating efficiency and reducing costs.
Patent Information
- Application Number
- CN202311544353.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-17
- Publication Date
- 2025-05-20
AI Technical Summary
The existing CDN preheating mechanism leads to waste of bandwidth, waste of storage resources, low preheating efficiency and high preheating costs.
By obtaining the warm-up node information corresponding to the target resource, a node suitable for performing the warm-up task is determined, and only responds to resource pull requests to the warm-up nodes, avoiding the non-warming nodes from performing the warm-up task.
The number of CDN nodes for preheating tasks is reduced, bandwidth and storage resources consumption is reduced, preheating efficiency is improved, and preheating costs are reduced.
Smart Images

Figure CN120021235A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of network communication technology, and in particular to a resource preheating method and related devices. Background Technology
[0002] Content Delivery Network (CDN) is a new layer of network architecture added on the basis of the existing Internet, which is used to distribute resources from the source station to the network edge nodes (i.e. CDN nodes closer to users), so that users can obtain the required resources faster.
[0003] In order to further improve the speed at which users obtain resources, CDN provides a resource preheating function. The resource preheating function is used to cache resources on CDN nodes in advance before users initiate resource acquisition requests, so that resource acquisition requests initiated by users can be responded to more quickly. In related technologies, resource preheating is performed at the granularity of the resource pool to which the domain name to which the resource belongs is connected, that is, all CDN nodes associated with a domain name must perform preheating tasks for specific resources under the domain name; this preheating method usually causes a large amount of bandwidth and storage resource waste, and has low preheating efficiency and high preheating costs. SUMMARY OF THE INVENTION
[0004] The embodiment of the present application provides a resource preheating method and related devices, which can reduce the bandwidth waste and storage resource waste caused by resource preheating, improve preheating efficiency, and reduce preheating costs.
[0005] In view of this, the first aspect of the present application provides a resource preheating method, the method comprising:
[0006] Acquire preheating node information corresponding to the target resource; the preheating node information is used to indicate the preheating node that performs the preheating task on the target resource, the preheating node is determined in each access node according to the operation status information of each access node corresponding to the target resource, and the access node is a content delivery network CDN node associated with the domain name to which the target resource belongs;
[0007] When receiving a resource pull request sent by a target access node, determining whether the target access node is the preheating node indicated by the preheating node information according to the preheating node information;
[0008] When it is determined that the target access node is the preheating node, a resource location identifier of the target resource is sent to the target access node so that the target access node acquires and caches the target resource based on the resource location identifier.
[0009] A second aspect of the present application provides a resource preheating device, the device comprising:
[0010] An obtaining module, configured to obtain warm-up node information corresponding to a target resource; the warm-up node information is used to indicate a warm-up node for performing a warm-up task on the target resource, and the warm-up node is determined from each of the access nodes according to the running state information of each access node corresponding to the target resource, and the access node is a content delivery network (CDN) node associated with the domain name to which the target resource belongs;
[0011] A determining module, configured to, when receiving a resource pulling request sent by a target access node, determine whether the target access node is the warm-up node indicated by the warm-up node information according to the warm-up node information;
[0012] A sending module, configured to, when it is determined that the target access node is the warm-up node, send a resource location identifier of the target resource to the target access node, so that the target access node obtains and caches the target resource based on the resource location identifier.
[0013] A third aspect of this application provides a computer device, which includes a processor and a memory:
[0014] The memory is used to store a computer program;
[0015] The processor is configured to execute the steps of the resource preheating method as described in the first aspect above according to the computer program.
[0016] A fourth aspect of this application provides a computer-readable storage medium, which is used to store a computer program, and the computer program is used to execute the steps of the resource preheating method as described in the first aspect above.
[0017] A fifth aspect of this application provides a computer program product or a computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the steps of the resource preheating method as described in the first aspect above.
[0018] It can be seen from the above technical solutions that the embodiments of this application have the following advantages:
[0019] The embodiments of the present application provide a resource preheating method. In this method, first, obtain the preheating node information corresponding to the target resource to be preheated. The preheating node information is used to indicate the preheating node for performing the preheating task on the target resource. The preheating node is determined from among the access nodes according to the operating status information of each access node corresponding to the target resource. The access node is a CDN node associated with the domain name to which the target resource belongs. Furthermore, when a resource pull request sent by a target access node is received, it can be determined whether the target access node is the preheating node indicated by the preheating node information according to the above preheating node information. If it is determined that the target access node is the preheating node, send the resource location identifier of the target resource to the target access node so that the target access node can obtain and cache the target resource accordingly, realizing the preheating of the target resource. If it is determined that the target access node is not the preheating node, the resource location identifier of the target resource will not be sent to the target access node. Correspondingly, the target access node cannot preheat the target resource. In this way, first, select, from among the access nodes, the preheating node suitable for preheating the target resource according to the respective operating status information of each access node corresponding to the target resource. Furthermore, only respond to the resource pull request sent by the preheating node by feedbacking the resource location identifier of the target resource, and will not feedback the resource location identifier of the target resource for the resource pull request sent by a non-preheating node, thereby avoiding all access nodes of the target resource from performing the preheating task on the target resource and reducing the number of CDN nodes performing the preheating task. In the case where the number of CDN nodes performing the preheating task is reduced, the bandwidth resources and storage resources consumed during the preheating task can be reduced accordingly, and the preheating efficiency can be improved and the preheating cost can be reduced. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 FIG. is a schematic structural diagram of an exemplary CDN provided by the embodiments of the present application;
[0021] Figure 2 FIG. is a schematic diagram of an application scenario of the resource preheating method provided by the embodiments of the present application;
[0022] Figure 3 FIG. is a schematic flowchart of the resource preheating method provided by the embodiments of the present application;
[0023] Figure 4 FIG. is a schematic diagram of a DNS scheduling provided by the embodiments of the present application;
[0024] Figure 5 FIG. is a schematic diagram of a geographical indication information provided by the embodiments of the present application;
[0025] Figure 6 FIG. is an architecture diagram of the resource preheating system provided by the embodiments of the present application;
[0026] Figure 7Schematic diagram of experimental results provided by embodiments of the present application;
[0027] Figure 8 Schematic diagram of the structure of the resource preheating device provided by embodiments of the present application;
[0028] Figure 9 Schematic diagram of the structure of the terminal device provided by embodiments of the present application;
[0029] Figure 10 Schematic diagram of the structure of the server provided by embodiments of the present application. Detailed implementation manners
[0030] In order to enable those skilled in the art to better understand the solution of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present application.
[0031] Terms such as "first", "second", "third", "fourth", etc. (if any) in the specification, claims and above-mentioned drawings of the present application are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application described here can be implemented in an order other than those illustrated or described here. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0032] In the related art, CDN nodes mainly rely on the CDN caching mechanism to ensure a quick response to resource access requests initiated by users; the CDN caching mechanism is a key function in the CDN, which is used to store resources on the CDN nodes. Specifically, when a user requests to access a certain resource through a CDN node, the CDN node will first check whether it has cached the resource itself; if the CDN node has cached the resource, the CDN node can directly feedback the resource to the user; if the CDN node has not cached the resource, the CDN node needs to request the resource from the upper-level CDN node or even the source station. After obtaining the resource, the resource is feedback to the user, and the resource is cached to itself, so that when subsequent access requests for the resource are received, the resource can be directly feedback to the corresponding user.
[0033] Based on the above CDN cache mechanism, although it can ensure timely response to most resource access requests, for the first access request to a resource that is not cached, the CDN node needs to trace back step by step to obtain the corresponding resource, and may even need to trace back to the source site to obtain the corresponding resource; it is obvious that it is difficult to respond quickly to the first access request to such resources that are not cached by CDN nodes, and it usually takes a long time to obtain the corresponding resource. In addition, when the above uncached resource is a newly launched popular resource, since the resource has just been launched, each CDN node has not yet cached the resource, and the resource has a large number of visits, it is very easy for a large number of CDN nodes to request the resource from the source site at the same time, which can easily cause the source site to crash and paralyze.
[0034] In order to solve the above problems existing in the CDN cache mechanism, the CDN preheating mechanism came into being. The CDN preheating mechanism is the resource preheating function provided by CDN. In the CDN preheating mechanism, the CDN node can autonomously imitate the user to initiate a resource access request, so as to cache the resource on the CDN node in advance before the user initiates the resource access request. In this way, even for the first access request to the resource, the CDN node can respond quickly; in addition, for the newly launched popular resources, the CDN node can preheat and cache the resource to itself before the resource goes online. Accordingly, after the resource goes online, the user can quickly obtain the resource directly from the CDN node that is closer, avoiding the situation where a large number of CDN nodes initiate a large number of resource acquisition requests to the source station.
[0035] In the related art, the above-mentioned CDN preheating mechanism is performed at the granularity of the resource pool to which the domain name to which the preheating resource belongs is connected, which means that the preheating task for the preheating resource needs to be executed on each CDN node to which the domain name is connected. Specifically, each CDN node in the CDN can be divided into a corresponding node cluster according to the function of the node or the program running on the node. The CDN nodes included in the same node cluster have the same function or run the same program. The node cluster can also be called a resource pool. In actual applications, the domain name can be connected to the corresponding resource pool that can support its business implementation according to the business provided by the domain name. Accordingly, each CDN node in the connected resource pool can obtain and cache the resources under the domain name. When preheating a specific resource provided by a domain name based on the CDN preheating mechanism, it is necessary to control each CDN node in the resource pool to which the domain name is connected to preheat the specific resource.
[0036] However, the above-mentioned method for implementing the CDN preheating mechanism has the following problems: 1) Resource waste: Usually, there are some CDN nodes in the CDN network that are in a disabled state or are not suitable for being accessed by users. If such CDN nodes are also made to execute the resource preheating task, then the bandwidth resources and storage resources consumed by these CDN nodes when executing the resource preheating task are essentially meaningless and belong to resource waste. 2) Low preheating efficiency: When all CDN nodes in each resource pool accessed by a domain name execute the resource preheating task, a large number of CDN nodes will request the resources to be preheated from the source station, that is, the number of preheating tasks to be executed is extremely large, which will correspondingly lead to a slow preheating speed and low preheating efficiency. 3) High preheating cost: Similarly, due to the extremely large number of preheating tasks to be executed, the preheating cost to be consumed is also relatively high.
[0037] Figure 1 This is a schematic structural diagram of an exemplary CDN provided by an embodiment of the present application. As Figure 1 shown, for the CDN nodes in the CDN network, they are divided into an edge layer, an intermediate layer, and an SOC layer. Among them, the CDN nodes in the edge layer are the closest to users, the CDN nodes in the SOC layer are the closest to the source station, and the CDN nodes in the intermediate layer are located between the CDN nodes in the edge layer and the CDN nodes in the SOC layer. Assume that the domain name of a certain source station accesses three resource pools. When a preheating task needs to be executed for a certain resource provided by this source station, each CDN node in the three resource pools accessed by the domain name of this source station correspondingly needs to execute the preheating task for this resource. As Figure 1 shown, the mid-5 node is in a disabled state, and the resource access request of the user will not be routed to this node. However, based on the implementation method of the CDN preheating mechanism in the related technology, the mid-5 node still needs to send a resource acquisition request for the resource to be preheated to the soc-3 node. If the soc-3 node has not stored this resource, the soc-3 node still needs to further request this resource from the source station. However, all kinds of resources (such as bandwidth resources, storage resources, etc.) consumed by the disabled mid-5 when executing the preheating task for the resource are meaningless, resulting in resource waste; and there are many CDN nodes that need to execute the preheating task, so the preheating efficiency will be relatively low and the consumed preheating cost will be relatively high.
[0038] To solve the above problems, an embodiment of the present application provides a resource preheating method. In this method, first, obtain the preheating node information corresponding to the target resource to be preheated. The preheating node information is used to indicate the preheating node for performing the preheating task on the target resource. The preheating node is determined from among the access nodes according to the operating status information of each access node corresponding to the target resource. The access node is a CDN node associated with the domain name to which the target resource belongs. Furthermore, when a resource pulling request sent by a target access node is received, it can be determined whether the target access node is the preheating node indicated by the preheating node information according to the above preheating node information. If it is determined that the target access node is the preheating node, send the resource location identifier of the target resource to the target access node, so that the target access node can obtain and cache the target resource accordingly, realizing the preheating of the target resource. If it is determined that the target access node is not the preheating node, the resource location identifier of the target resource will not be sent to the target access node. Correspondingly, the target access node cannot preheat the target resource.
[0039] In this way, a preheating node suitable for preheating the target resource is selected from among the access nodes in advance according to the operating status information of each access node corresponding to the target resource. Furthermore, only the resource location identifier of the target resource is fed back in response to the resource pulling request sent by the preheating node, and the resource location identifier of the target resource will not be fed back for the resource pulling request sent by a non-preheating node, thereby avoiding all access nodes of the target resource from performing the preheating task on the target resource, reducing the number of CDN nodes performing the preheating task. When the number of CDN nodes performing the preheating task is reduced, the bandwidth resources and storage resources consumed during the preheating task can be correspondingly reduced, and the preheating efficiency can be improved, and the preheating cost can be reduced.
[0040] It should be noted that the resource preheating method provided by the embodiment of the present application can be executed by a computer device, and the computer device can be a terminal device or a server. Among them, the terminal device includes but is not limited to mobile phones, computers, intelligent voice interaction devices, intelligent home appliances, vehicle-mounted terminals, aircraft, etc. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server.
[0041] It should be noted that the information, data, and signals involved in the embodiment of the present application are all authorized by the relevant objects or fully authorized by all parties, and the collection, use, and processing of the relevant data all comply with the relevant laws, regulations, and standards of the relevant countries and regions.
[0042] To facilitate the understanding of the resource preheating method provided by the embodiment of the present application, the application scenario of the resource preheating method will be exemplarily introduced below by taking the execution entity of the resource preheating method as a server.
[0043] See Figure 2 , Figure 2 , which is a schematic diagram of the application scenario of the resource preheating method provided by the embodiment of the present application. As Figure 2 shown, this application scenario includes server 210, server 220, and server 230. Server 210 and server 220, server 230 can communicate through the network. Server 210 is used to execute the resource preheating method provided by the embodiment of the present application, control the preheating node corresponding to the target resource to be preheated to execute the preheating task for the target resource, and at the same time avoid non-preheating nodes from executing the preheating task for the target resource; both server 220 and server 230 are CDN nodes, specifically the access nodes corresponding to the target resource to be preheated, that is, the CDN nodes associated with the domain name to which the target resource belongs.
[0044] In practical applications, server 210 can pre-obtain the preheating node information corresponding to the target resource to be preheated. The preheating node information is used to indicate the preheating node that executes the preheating task for the target resource. The preheating node is determined among the respective access nodes according to the respective running state information of the access nodes corresponding to the target resource; specifically, the preheating node can be an access node whose running state supports user access to it. The above access nodes are CDN nodes associated with the domain name to which the target resource belongs, Figure 2 and both server 220 and server 230 in
[0045] belong to the access nodes corresponding to the target resource.
[0046] Server 220 and server 230 can send resource pull requests to server 210. After receiving the resource pull requests sent by server 220 and server 230, server 210 can determine whether server 220 is the preheating node indicated by the preheating node information according to the preheating node information corresponding to the target resource, and determine whether server 230 is the preheating node indicated by the preheating node information.
[0047] In this way, only the access nodes whose running status is suitable for the object to access the target resource need to warm up the target resource, and the access nodes whose running status is not suitable for the object to access the target resource do not need to warm up the target resource, reducing the waste of bandwidth resources and storage resources caused by warming up the target resource. At the same time, since the number of CDN nodes that need to execute the warm-up task is reduced, the warm-up efficiency can be correspondingly improved and the warm-up cost can be reduced.
[0048] It should be understood that Figure 2 the application scenarios shown are only examples. In actual applications, the resource warm-up method provided by the embodiments of the present application can also be applied to other scenarios, and no limitations are imposed on the application scenarios of the resource warm-up method provided by the embodiments of the present application here.
[0049] The resource warm-up method provided by the present application will be introduced in detail below through method embodiments.
[0050] See Figure 3 , Figure 3 which is a schematic flowchart of the resource warm-up method provided by the embodiments of the present application. For the convenience of description, the following takes the server as the execution subject of the resource warm-up method as an example for introduction. As Figure 3 shown, the resource warm-up method includes the following steps:
[0051] Step 301: Obtain warm-up node information corresponding to the target resource; the warm-up node information is used to indicate the warm-up nodes that execute the warm-up task for the target resource, and the warm-up nodes are determined from each of the access nodes according to the running status information of each access node corresponding to the target resource, and the access nodes are content delivery network (CDN) nodes associated with the domain name to which the target resource belongs.
[0052] In actual applications, the server can receive a warm-up request for the target resource initiated by the resource provider. The warm-up request is used to trigger the relevant nodes in the CDN to obtain and cache the target resource, so as to realize the warm-up of the target resource. The server responds to the warm-up request for the target resource and controls the relevant nodes in the CDN to execute the warm-up task for the target resource.
[0053] In an embodiment of the present application, when the server controls relevant nodes in the CDN to execute the warm-up task for the target resource, it is necessary to first obtain the warm-up node information corresponding to the target resource. The warm-up node information is used to indicate the warm-up nodes that execute the warm-up task for the target resource, that is, to indicate which specific CDN nodes need to warm up the target resource; the warm-up node information can be represented, for example, as a list of Internet Protocol Addresses (IP addresses), and the IP address list includes the IP addresses of each CDN node that needs to execute the warm-up task for the target resource. The warm-up nodes indicated by the warm-up node information are determined among the access nodes corresponding to the target resource. The access nodes corresponding to the target resource are CDN nodes associated with the domain name to which the target resource belongs, that is, the CDN nodes accessed by the domain name to which the target resource belongs; specifically, when determining the warm-up nodes among the access nodes corresponding to the target resource, according to the respective operating status information of each access node, the access nodes whose operating status can support the object to access them can be determined among the access nodes as the warm-up nodes. For example, the access nodes that are not in the disabled state, have better network quality, and lower load can be selected as the warm-up nodes among the access nodes. The specific implementation manner of determining the warm-up nodes will be introduced in detail below, and specific reference can be made to the relevant content below.
[0054] In this way, obtaining the warm-up node information corresponding to the target resource and controlling the warm-up nodes to warm up the target resource based on the warm-up node information, and the non-warm-up nodes do not need to warm up the target resource. In this way, it is avoided that the access nodes whose operating status is not suitable for the object to access them also execute the warm-up task for the target resource, reducing unnecessary resource waste, while reducing the number of CDN nodes executing the warm-up task, improving the warm-up efficiency, and reducing the warm-up cost.
[0055] It should be understood that the target resource in the embodiment of the present application can be any resource that needs to be warmed up; for example, the target resource can be a popular resource to be launched soon, such as the installation package of a certain game application to be launched soon, a certain multimedia resource to be launched soon (such as video resources, audio resources, text resources, etc.). No specific limitation is made on the target resource here.
[0056] Step 302: When receiving a resource pull request sent by the target access node, determine whether the target access node is the warm-up node indicated by the warm-up node information according to the warm-up node information.
[0057] For a CDN node, it can periodically send a resource pull request to the server so as to obtain and cache the resource in time when there is a resource to be warmed up under the accessed domain name.
[0058] In an embodiment of the present application, the target access node may periodically send a resource pulling request to the server. The target access node may be any one of the access nodes corresponding to the above-mentioned target resources; the resource pulling request is used to request to obtain the resources that the node itself has not cached from the server, and the IP address of the target access node is usually carried in the resource pulling request.
[0059] After receiving the resource pulling request sent by the target access node, the server may determine whether the target access node is the preheating node indicated by the preheating node information according to the preheating node information obtained in step 301. For example, when the preheating node information is a list of IP addresses of the preheating nodes, it may be determined whether the IP address of the target access node belongs to the list of IP addresses of the preheating nodes according to the IP address of the target access node carried in the received resource pulling request, so as to determine whether the target access node is a preheating node.
[0060] Step 303: When it is determined that the target access node is the preheating node, send the resource location identifier of the target resource to the target access node, so that the target access node can obtain and cache the target resource based on the resource location identifier.
[0061] When it is determined that the target access node that sends the resource pulling request is the preheating node indicated by the preheating node information, the server may return the resource location identifier of the target resource to be preheated, that is, the resource locator (Uniform Resource Locator, URL) of the target resource, to the target access node. Accordingly, the target access node may trace back layer by layer according to the resource location identifier of the target resource to obtain and cache the target resource.
[0062] For example, when the target access node is a CDN node in the edge layer, the target access node may send a resource acquisition request carrying the resource location identifier to a CDN node in the middle layer, so that the CDN node in the middle layer can check whether it has the target resource according to the resource location identifier; if it exists, the target resource will be sent to the target access node. If it does not exist, the CDN node in the middle layer will send a resource acquisition request carrying the resource location identifier to a CDN node in the SOC layer, so that the CDN node in the SOC layer can check whether it has the target resource according to the resource location identifier; if it exists, the target resource will be sent to the CDN node in the middle layer, and the CDN node in the middle layer will acquire and cache the target resource, and then send the target resource to the target access node. If it does not exist, the CDN node in the SOC layer will send a resource acquisition request carrying the resource location identifier to the origin server, acquire and cache the target resource from the origin server, and send the target resource to the CDN node in the middle layer. The CDN node in the middle layer will acquire and cache the target resource, and then send the target resource to the target access node.
[0063] It should be understood that when the target access node is a CDN node in the middle layer or a CDN node in the SOC layer, it also needs to perform a resource backtracking process similar to the above process until the target resource is obtained.
[0064] In the case where it is determined that the target access node sending the resource pull request is not the preheating node indicated by the preheating node information, the server may return response information to the target access node, and the response information is used to indicate that the target access node currently does not have the resource that needs to be preheated and cached. In this way, the target access node does not need to perform the preheating task for the target resource.
[0065] In the resource preheating method provided in the embodiments of the present application, preheating nodes suitable for preheating the target resource are selected from each access node according to the respective operating status information of each access node corresponding to the target resource; furthermore, only the resource location identifier of the target resource is fed back in response to the resource pull request sent by the preheating node, and the resource location identifier of the target resource is not fed back for the resource pull request sent by a non-preheating node, thereby avoiding all access nodes of the target resource from performing the preheating task for the target resource, reducing the number of CDN nodes performing the preheating task; in the case where the number of CDN nodes performing the preheating task is reduced, the bandwidth resources and storage resources consumed during the preheating task can be correspondingly reduced, and the preheating efficiency can be improved and the preheating cost can be reduced.
[0066] In a possible implementation manner, the DNS server may determine the preheating node for performing the preheating task on the target resource in the following manner:
[0067] Obtain the running status information of each access node. The running status information includes at least one of the network condition, load condition, and heartbeat data of the access node. Based on the Domain Name System (DNS) scheduling policy, determine, according to the running status information of each access node, the nodes whose running status meets the preset status condition among the access nodes as warm-up nodes; the preset status condition here is used to measure whether a CDN node is suitable for being accessed by an object.
[0068] It should be noted that DNS scheduling is a widely used traffic scheduling method, also known as global server load balancing; its basic principle is to guide the resource access request initiated by an object to the corresponding IP address by controlling the DNS resolution result of the CDN domain name, so as to achieve effective management of traffic.
[0069] Figure 4 This is a schematic diagram of a DNS scheduling provided by an embodiment of the present application. As Figure 4 shown, an object can initiate a domain name resolution request carrying a specific domain name to the local DNS server. Then, the local DNS server forwards the domain name resolution request carrying the specific domain name to the authoritative DNS server; after receiving the domain name resolution request, the authoritative DNS server can query the internal database to determine all the server IP addresses associated with the specific domain name carried by the domain name resolution request, and adopt the DNS scheduling policy to select the server IP address that is more suitable for the object to access from the determined server IP addresses. For example, comprehensively considering factors such as the load condition and network quality of each server, select the server IP address that is more suitable for the object to access; then, the authoritative DNS server feeds back the selected server IP address to the local DNS server, and then the local DNS server feeds it back to the object that initiated the domain name resolution request. Correspondingly, the object can access the corresponding server according to the received server IP address to obtain the corresponding resources.
[0070] In the embodiment of the present application, by means of the policy related to the above DNS scheduling, among the various CDN nodes (i.e., access nodes) accessed by the domain name to which the target resource belongs, determine the CDN node that is suitable for responding to the resource access request initiated by the object, that is, determine the CDN node that is suitable for supporting the object to access the target resource as the warm-up node.
[0071] Specifically, each access node associated with the domain name to which the target resource belongs can periodically report its own operating status information to the DNS server. The reported operating status information can include at least one of its own network conditions, load conditions, and heartbeat data; among them, the network condition can be the bandwidth usage of the access node, which is used to characterize the occupied bandwidth of the access node; the load condition can be the operating load of the access node, which is used to characterize the occupancy of the operating resources of the access node; the heartbeat data is used to characterize whether the access node is operating normally.
[0072] After the DNS server receives the operating status information reported by the access node, it can determine whether the access node meets the preset status condition based on the DNS scheduling policy and according to the operating status reflected by the operating status information of the access node. The preset status condition is a condition preset for measuring whether a CDN node is suitable for being accessed by an object. If it is determined that the access node meets the preset status condition, it means that the access node is suitable for being accessed by the object. Then, it is very likely that the access node will subsequently receive an access request for the target resource initiated by the object. Therefore, it is necessary to use this access node as the warm-up node corresponding to the target resource, make it execute the warm-up task for the target resource, and cache the target resource in advance, so as to facilitate timely response to the access request for the target resource initiated by the object subsequently. If it is determined that the access node does not meet the preset status condition, it means that the access node is not suitable for being accessed by the object. Then, it is very likely that the access node will not subsequently receive an access request for the target resource initiated by the object. Therefore, there is no need to use this access node as the warm-up node corresponding to the target resource, nor is it necessary to make this access node execute the warm-up task for the target resource, so as to avoid unnecessary resource waste.
[0073] Exemplarily, when determining whether an access node meets the preset status condition based on the DNS scheduling policy, it can be judged whether the network quality of the access node reaches the preset network quality requirement, and the access node with the network quality reaching this network quality requirement can be used as the warm-up node; it can also be judged whether the load of the access node exceeds the preset load threshold, and the access node with the load not exceeding this load threshold can be used as the warm-up node; it can also be judged whether the heartbeat data of the access node is normal, and the access node with normal heartbeat data can be used as the warm-up node. Of course, in practical applications, it is also possible to comprehensively consider the above two or three judgment conditions to determine whether to use a certain access node as the warm-up node. The embodiments of the present application do not make any limitations in this regard.
[0074] It should be understood that after the DNS server determines the warm-up node corresponding to the target resource, it can correspondingly generate the warm-up node information corresponding to the target resource according to the IP addresses of each warm-up node, and provide this warm-up node information to the server used to control the execution of the warm-up task of the target resource, that is, the server for executing Figure 3 the embodiment shown.
[0075] In this way, through the above method, the warm-up nodes that need to execute the warm-up task for the target resource can be determined based on the DNS scheduling policy, ensuring the accuracy and reliability of the determined warm-up nodes. In the embodiments of the present application, the DNS scheduling policy used to schedule real user requests is reused to determine the warm-up nodes, so as to ensure that the determined warm-up nodes are the servers accessed by the real user requests, that is, to ensure that the determined warm-up nodes will probably receive access requests for the target resource subsequently. Let the warm-up nodes that are likely to be accessed by users execute the warm-up task for the target resource, which can more effectively avoid wasting relevant resources.
[0076] In a possible implementation manner, during the process of determining the warm-up nodes, the method provided by the embodiments of the present application may further include:
[0077] Obtain the regional indication information corresponding to the target resource, where the regional indication information is used to indicate the region faced by the target resource.
[0078] Correspondingly, when specifically determining the warm-up nodes, it is necessary to determine, based on the domain name system scheduling policy and the regional indication information, among the access nodes, the nodes whose operating status meets the preset status conditions and whose affiliated region is the region indicated by the regional indication information, as the warm-up nodes.
[0079] In the embodiments of the present application, the DNS server may also receive the regional indication information corresponding to the target resource provided by the resource provider, where the regional indication information is used to indicate the region faced by the target resource, that is, to indicate the region to which the object mainly faced by the target resource belongs. For example, assume that the target resource is the installation package of an application program, and the users mainly faced by the application program are users in region A. Then the resource provider can input the regional indication information through the set manual access interface to indicate that the region faced by the application program is region A.
[0080] Correspondingly, when the DNS server determines the warm-up nodes among the access nodes associated with the domain name to which the target resource belongs, it is necessary to consider both the DNS scheduling policy and the regional indication information corresponding to the target resource, and determine, among the access nodes, the access nodes whose operating status meets the preset status conditions and whose affiliated region is the region indicated by the regional indication information, as the warm-up nodes, that is, select the access nodes whose own operating status is suitable for being accessed by the object and whose own affiliated region is the region faced by the target resource, as the warm-up nodes.
[0081] In this way, through the above method, based on the DNS scheduling policy, further combined with the geographical indication information corresponding to the target resource, the preheating nodes for executing the preheating task on the target resource can be determined among the respective access nodes corresponding to the target resource, which can further improve the accuracy and reliability of the determined preheating nodes, enabling the access nodes deployed within the geographical area faced by the target resource and with a running state suitable for object access to preheat the target resource, thereby further reducing the resource waste caused by preheating, improving the preheating efficiency, and reducing the preheating cost.
[0082] In a possible implementation manner, the above geographical indication information is further used to indicate the respective priorities corresponding to the respective geographical areas faced by the target resource; correspondingly, the method provided in the embodiments of the present application may further include:
[0083] Determine the respective priorities corresponding to the respective preheating nodes according to the respective priorities corresponding to the respective geographical areas indicated by the geographical indication information and the respective geographical areas to which the respective preheating nodes belong.
[0084] In the embodiments of the present application, in addition to setting the respective geographical areas faced by the target resource, the resource provider of the target resource may also set the respective priorities corresponding to the respective geographical areas faced. It should be understood that the priority corresponding to the geographical area is used to represent the routing priority for the access request to the target resource. For example, Figure 5 FIG. is a schematic diagram of a geographical indication information provided in the embodiments of the present application. As Figure 5 shown, assume that the geographical areas faced by the target resource are Area A and Area B. CDN nodes are deployed in both Area A1 and Area A2 in Area A, and CDN nodes are deployed in both Area B1, Area B2, and Area B3 in Area B; the geographical indication information may indicate that the priority of Area A1 is higher than that of Area A2, the priority of Area B1 is higher than that of Area B2, and the priority of Area B2 is higher than that of Area B3; thus, when the DNS server receives an access request for the target resource from Area A, it will preferentially route the resource access request to the CDN node deployed within Area A1, and when the CDN node deployed within Area A1 does not support access, it will then route the access request to the CDN node deployed within Area A2; when the DNS server receives an access request for the target resource from Area B, it will preferentially route the resource access request to the CDN node deployed within Area B1, and when the CDN node deployed within Area B1 does not support access, it will then route the access request to the CDN node deployed within Area B2; when the CDN node deployed within Area B2 does not support access, it will then route the access request to the CDN node deployed within Area B3.
[0085] Based on the priorities corresponding to each region that the target resource indicated by the regional indication information faces, the DNS server can further configure priorities for each determined warm-up node; specifically, if the region to which a warm-up node belongs has a relatively high priority, correspondingly, a relatively high priority can be configured for this warm-up node, and if the region to which a warm-up node belongs has a relatively low priority, correspondingly, a relatively low priority can be configured for this warm-up node. It should be understood that resource pull requests initiated by warm-up nodes with higher priorities can be preferentially responded to, while resource pull requests initiated by warm-up nodes with lower priorities are usually responded to later.
[0086] In this way, through the above method, according to the priorities corresponding to each region that the target resource indicated by the regional indication information faces, the priorities of the warm-up nodes belonging to different regions are correspondingly configured, so as to facilitate determining the corresponding response order according to the priorities of the warm-up nodes that initiate resource pull requests later, so as to preferentially warm up the target resource by the warm-up nodes with higher priorities, that is, to preferentially warm up the target resource by the warm-up nodes in the regions with higher priorities, and improve the reliability of the target resource warm-up task.
[0087] In a possible implementation manner, during the process of determining the warm-up nodes, the method provided by the embodiments of the present application may further include:
[0088] Obtain the object access logs of each access node; according to the object access logs of each access node, determine frequently accessed nodes among the access nodes whose access conditions meet the preset access conditions; the preset access conditions are used to measure whether the access conditions of the CDN nodes meet the preset frequency requirements.
[0089] Correspondingly, when specifically determining the warm-up nodes, it is necessary to determine, among each access node, a node whose operating state meets the preset state conditions and belongs to the frequently accessed nodes as the warm-up node.
[0090] In the embodiment of the present application, the DNS server can also analyze the access behavior of the object to determine, among the access nodes corresponding to the target resource, the access nodes frequently accessed by the object as the frequently accessed nodes. Specifically, the DNS server can obtain the object access logs of each access node. For example, it can obtain the object access logs of each access node within a preset time period (such as the last month or the last week); then, statistically analyze each obtained object access log to determine the access situation corresponding to each access node. For example, for each access node, it can count the number of times the access node is accessed within the preset time period; furthermore, among the access nodes, determine the access nodes that meet the preset access conditions as the frequently accessed nodes. The preset access conditions are conditions pre-set for measuring whether a CDN node meets the preset frequency requirement, which can be manifested as, for example, a threshold of the number of access times. If the number of times an access node is accessed within the preset time period exceeds the threshold of the number of access times, it can be considered that the access node meets the preset access conditions and belongs to the frequently accessed nodes.
[0091] It should be understood that in practical applications, other methods can also be used to analyze the object access logs of each access node, and other forms of preset access conditions can be used to determine the frequently accessed nodes among the access nodes. The embodiment of the present application does not make any limitation in this regard.
[0092] Correspondingly, when the DNS server determines the preheating nodes among the access nodes corresponding to the target resource, it should consider both the DNS scheduling policy and the access situation of the access nodes, and determine, among the access nodes, the access nodes whose running status meets the preset status conditions and belong to the above-mentioned frequently accessed nodes as the preheating nodes, that is, select the access nodes whose running status is suitable for being accessed by the object and are frequently accessed by the object as the preheating nodes.
[0093] In this way, through the above method, on the basis of the DNS scheduling policy, further combined with the access situation of the access nodes, determine the preheating nodes that perform the preheating task on the target resource among the access nodes corresponding to the target resource, which can further improve the accuracy and reliability of the determined preheating nodes, so that the access nodes that are frequently accessed by the object and whose running status is suitable for object access preheat the target resource, which can further reduce the resource waste caused by preheating, improve the preheating efficiency, and reduce the preheating cost.
[0094] In a possible implementation manner, the method provided by the embodiment of the present application may further include:
[0095] According to the object access logs of each preheating node, determine the corresponding priority of each preheating node, and the priority is positively correlated with the access frequency characterized by the object access log.
[0096] In the embodiment of the present application, the DNS server may also determine the access frequency of each preheating node according to the object access logs of each preheating node determined. For example, for each preheating node, the DNS server may count the number of times the preheating node is accessed within a preset time period (such as the recent month or the recent week) according to the object access log of the preheating node within the preset time period, and then determine the number interval to which the number of access times belongs according to the mapping relationship between the preset number intervals and the access frequency, and determine the access frequency corresponding to the number interval as the access frequency corresponding to the preheating node.
[0097] Then, according to the access frequency corresponding to each preheating node, configure priorities for each preheating node accordingly; the higher the access frequency corresponding to a preheating node, the higher the priority configured for the preheating node, and the lower the access frequency corresponding to a preheating node, the lower the priority configured for the preheating node. It should be understood that the resource pulling requests initiated by the preheating nodes with higher priorities can be preferentially responded to, while the resource pulling requests initiated by the preheating nodes with lower priorities are usually responded to later.
[0098] In this way, through the above method, configure priorities for the preheating nodes according to the access frequency corresponding to the preheating nodes, so as to facilitate determining the corresponding response order according to the priorities of the preheating nodes that initiate resource pulling requests subsequently, so as to preferentially preheat the target resources by the preheating nodes with higher priorities, that is, to preferentially preheat the target resources by the preheating nodes that are frequently accessed by the object, and improve the reliability of the target resource preheating task.
[0099] It should be understood that in practical applications, the DNS server may also comprehensively consider the DNS scheduling policy, the region to which the target resource is oriented indicated by the region indication information, and the object access situations of each access node corresponding to the target resource, and determine the preheating nodes for preheating the target resource among the access nodes; for example, determine the access nodes that meet the preset state conditions, whose region belongs to the region indicated by the region indication information, and are frequently accessed by the object among the access nodes as the preheating nodes, and the embodiment of the present application does not make any limitations on this.
[0100] In addition, the DNS server may also comprehensively consider the priorities corresponding to each region indicated by the region indication information and the access frequency of the preheating nodes to determine the priorities corresponding to each preheating node; for example, a higher priority may be configured for the preheating node whose corresponding region has a higher priority and whose access frequency is higher, and a lower priority may be configured for the preheating node whose corresponding region has a lower priority and whose access frequency is lower; the embodiment of the present application does not make any limitations on this.
[0101] In a possible implementation, when each warm-up node used to perform the warm-up task on the target resource has its own corresponding priority, "sending the resource location identifier of the target resource to the target access node" in step 303 includes:
[0102] In the case of receiving resource pull requests sent by multiple target access nodes and determining that all the multiple target access nodes are warm-up nodes, determine the request response order according to the respective priorities of the multiple target access nodes; and send the resource location identifier of the target resource to the multiple target access nodes in accordance with this request response order.
[0103] Exemplarily, assume that the server simultaneously receives resource pull requests sent by target access node a, target access node b, target access node c, and target access node d. If the server determines, according to the warm-up node information corresponding to the target resource, that target access node a, target access node b, and target access node c are the warm-up nodes indicated by the warm-up node information, then the server needs to respond to the resource pull requests sent by target access node a, target access node b, and target access node c respectively, and correspondingly feedback the resource location identifier of the target resource to them.
[0104] Assume that the priority of target access node a is higher than the priority of target access node b, and the priority of target access node b is higher than the priority of target access node c. Then the server can determine the request response order as follows: first respond to the resource pull request sent by target access node a, then respond to the resource pull request sent by target access node b, and finally respond to the resource pull request sent by target access node c. Correspondingly, the server can first send the resource location identifier of the target resource to target access node a, then send the resource location identifier of the target resource to target access node b, and finally send the resource location identifier of the target resource to target access node c.
[0105] In this way, through the above method, when resource pull requests sent by multiple warm-up nodes are received simultaneously, according to the respective priorities of these multiple warm-up nodes, sequentially respond to the resource pull requests sent by these multiple warm-up nodes respectively and feedback the resource location identifier of the target resource, which can improve the reliability of the target resource warm-up task and avoid the situation that the warm-up of the target resource fails for some nodes due to simultaneously responding to a large number of resource pull requests.
[0106] In a possible implementation, before sending the resource location identifier of the target resource to the warm-up node, the method provided by the embodiments of the present application further includes:
[0107] For each access node cluster corresponding to the target resource, determine the preheating bandwidth corresponding to the access node cluster according to the bandwidth usage of the access node cluster; the access node cluster is a CDN node cluster accessed by the domain name to which the target resource belongs, and an access node cluster includes access nodes with the same function.
[0108] For each access node cluster, based on the preheating bandwidth corresponding to the access node cluster, split the target resource to obtain multiple target sub-resources corresponding to the access node cluster, and determine the resource location identifiers of these multiple target sub-resources respectively.
[0109] In the embodiments of the present application, the server for controlling the preheating task of the target resource can also control the preheating bandwidth corresponding to each access node cluster, so that each access node cluster performs the preheating task for the target resource based on the corresponding preheating bandwidth.
[0110] Specifically, for CDN, usually according to the function of the node or the program running on the node, each CDN node included is divided into the corresponding node cluster. Each CDN node included in the same node cluster has the same function or runs the same program, and this node cluster can also be called a resource pool or a platform. In practical applications, for the domain name accessing the CDN, according to the service provided by the domain name, the domain name can be accessed to the corresponding node cluster that can support the realization of its service, and each CDN node in the accessed node cluster can obtain and cache the resources under the domain name.
[0111] In the embodiments of the present application, the node cluster accessed by the domain name to which the target resource belongs is regarded as the access node cluster corresponding to the target resource. For each access node cluster corresponding to the target resource, the server can obtain the bandwidth usage of the access node cluster through the DNS server; specifically, the DNS server can obtain the bandwidth usage reported by each access node. Correspondingly, the DNS server can count the bandwidth usage of each access node cluster according to the bandwidth usage reported by each access node and the access node cluster to which each access node belongs, and send the bandwidth usage of the access node cluster to the server for controlling the preheating task of the target resource.
[0112] After the server obtains the bandwidth usage of the access node cluster, it can determine the preheating bandwidth corresponding to the access node cluster according to the bandwidth usage of the access node cluster. For example, if the bandwidth usage of the access node cluster indicates that the bandwidth occupancy rate of the access node cluster is relatively high, then a lower preheating bandwidth can be configured for the access node cluster, so that the preheating nodes in the access node cluster can obtain the target resources based on the lower preheating bandwidth, avoiding the preheating task of the target resources from affecting other services related to the access node cluster; conversely, if the bandwidth usage of the access node cluster indicates that the bandwidth occupancy rate of the access node cluster is relatively low, then a higher preheating bandwidth can be configured for the access node cluster, so that the preheating nodes of the access node cluster can obtain the target resources based on the higher preheating bandwidth and quickly complete the preheating task for the target resources.
[0113] In order to control the access node cluster to execute the preheating task of the target resources based on the preheating bandwidth configured for it, the server needs to, for each access node cluster, split the target resources according to the preheating bandwidth corresponding to the access node cluster to obtain multiple target sub-resources corresponding to the access node cluster; for example, assume that the preheating bandwidth configured for an access node cluster is 100M, and the size of the target resource is 880M, then the target resource can be split into 9 target sub-resources, where the size of 8 target sub-resources is 100M and the size of 1 target sub-resource is 80M. At the same time, the server also needs to configure a corresponding resource location identifier for each target sub-resource obtained by splitting, so that the preheating nodes can obtain each target sub-resource one by one according to the resource location identifier for caching.
[0114] In this way, through the above method, for each access node cluster corresponding to the target resources, according to the bandwidth usage of the access node cluster, a corresponding preheating bandwidth for executing the preheating task of the target resources is configured for the access node cluster; and by splitting the target resources according to the preheating bandwidth, the preheating nodes in the access node cluster can execute the preheating task of the target resources according to the corresponding preheating bandwidth. Considering the actual bandwidth occupancy in the access node cluster and correspondingly allocating the corresponding preheating bandwidth for the access node cluster can ensure that the preheating task of the target resources does not affect the progress of other services in the access node cluster, and at the same time ensure the rational use of the bandwidth of the access node cluster, neither overly occupying too much bandwidth, resulting in the services supported by the access node cluster being unable to operate normally, nor avoiding excessive bandwidth idle, resulting in waste of bandwidth resources.
[0115] In a possible implementation manner, in the case where the target resource is split into multiple target sub-resources, "sending the resource location identifier of the target resource to the target access node" in step 303 may specifically include:
[0116] Send the resource location identifier of the i-th target sub-resource to the target access node. The i-th target sub-resource ranks the i-th among the n target sub-resources corresponding to the access node cluster to which the target access node belongs. i is an integer greater than or equal to 1 and less than or equal to n, and n is an integer greater than 1.
[0117] Receive the resource caching result of the i-th target sub-resource returned by the target access node. The resource caching result is generated by the target access node after completing the preheating task for the i-th target sub-resource based on the resource location identifier of the i-th target sub-resource.
[0118] If i is less than n, send the resource location identifier of the (i + 1)-th target sub-resource to the target access node; if i is equal to n, determine that the target access node has completed the preheating task for the target resource.
[0119] Specifically, assume that the server determines that the target access node belongs to the access node cluster Q, and the server divides the target resource into n target sub-resources according to the preheating bandwidth corresponding to the access node cluster Q. Then, after the server receives the resource pull request sent by the target access node and determines that the target access node belongs to the preheating node, it can send the resource location identifier of the first target sub-resource among the n target sub-resources to the target access node. Correspondingly, the target access node can obtain the first target sub-resource from the upper-layer CDN node or the source station based on the resource location identifier of the first target sub-resource, and cache the obtained first target sub-resource. After the target access node completes the preheating task for the first target sub-resource, the target access node can send the resource caching result of the first target sub-resource to the server to inform the server that it has completed the preheating task for the first target sub-resource. After receiving the resource caching result, the server can continue to send the resource location identifier of the second target sub-resource among the n target sub-resources to the target access node, so that the target access node can complete the preheating task for the second target sub-resource according to the above process. And so on, until the target access node completes the preheating task for the n-th target sub-resource.
[0120] In this way, through the above method, the target access node as the preheating node can sequentially obtain each target sub-resource one by one, so as to implement the preheating task for the target resource according to the preheating bandwidth configured by the server for the access node cluster to which it belongs, and ensure that the execution of the preheating task does not affect the operation of other services in the access node cluster to which it belongs.
[0121] In a possible implementation manner, the method provided in the embodiments of the present application further includes:
[0122] Receive a warm-up task query request for a target resource. In response to the warm-up task query request, determine the execution status of the warm-up task corresponding to the target resource according to the currently received resource cache result.
[0123] In an embodiment of the present application, the resource provider of the target resource may also initiate a warm-up task query request for the target resource. The warm-up task query request is used to request a query on the current execution status of the warm-up task of the target resource, such as querying the current execution progress of the warm-up task of the target resource.
[0124] Correspondingly, after the server receives a warm-up task query request for a target resource, it can perform statistical analysis based on the currently received resource cache result to determine the current execution status of the warm-up task corresponding to the target resource. It should be understood that the resource cache result here is the resource cache result fed back by the target access node to the server after completing the warm-up task for a certain target sub-resource as introduced above, which is used to represent that the warm-up task for the target sub-resource has been completed.
[0125] Exemplarily, for each target access node belonging to the warm-up node, the server can determine the execution progress of the warm-up task of the target access node for the target resource according to the currently fed-back resource cache result of the target access node. For example, assume that the resource cache result fed back by the target access node most recently represents that it has completed the warm-up task for the 5th target sub-resource, and the access node cluster to which the target access node belongs corresponds to a total of 10 target sub-resources. Then, it can be determined that the current execution progress of the warm-up task of the target access node for the target resource is 50%. In this way, determine the execution progress of the warm-up tasks of each warm-up node for the target resource and feedback it to the resource provider of the target resource so that it can know the current execution status of the warm-up task corresponding to the target resource. Of course, in practical applications, the server can also statistically analyze the execution status of the warm-up task corresponding to the target resource from other dimensions (such as the dimension of the access node cluster), and the embodiments of the present application do not make any limitations on this.
[0126] It should be understood that in practical applications, the above resource cache result can be first cached in the memory of the server so that the server can quickly respond to relevant warm-up task query requests based on this. At the same time, the resource cache result can also be synchronously stored on the hard disk of the server to store the resource cache result more regularly and persistently, facilitating the response to future relevant query requests based on this.
[0127] In this way, through the above method, the resource provider that supports the target resource can query the execution status of the warm-up task corresponding to the target resource, and based on the resource caching results fed back by the target access node acting as the warm-up node, finely count the current execution status of the warm-up task corresponding to the target resource, so as to facilitate the resource provider to more intuitively and detailedly understand the execution status of the warm-up task corresponding to the target resource.
[0128] In a possible implementation manner, the method provided by the embodiments of the present application further includes:
[0129] When a preset time condition is satisfied, according to the received resource caching results, in each warm-up node corresponding to the target resource, determine whether there is an un-warmed-up node that has not completed the warm-up task for the target resource.
[0130] In the case where it is determined that there is an un-warmed-up node, trigger a warm-up retry task for this un-warmed-up node; this warm-up retry task is used to make this un-warmed-up node execute the warm-up task for the target resource.
[0131] In the embodiments of the present application, when it is determined that the current preset time condition is satisfied, the preset time condition may be, for example, that the current time reaches a preset duration since the resource provider initiated the warm-up task for the target resource, and the preset duration may be, for example, 12 hours; the server can, according to the received resource caching results fed back by each target access node acting as a warm-up node, determine whether there is an un-warmed-up node that has not completed the warm-up task for this target resource in each warm-up node corresponding to the target resource. For example, assume that the warm-up nodes corresponding to the target resource include node a, node b, node c, node d, node e, and node f. Among them, the resource caching results recently fed back by node a, node b, node c, and node d all indicate that they have completed the warm-up task for the target resource, while the server has never received the resource caching results fed back by node e and node f. Then it can be determined that node e and node f have not completed the warm-up task for the target resource. Correspondingly, node e and node f can be determined as un-warmed-up nodes.
[0132] In the case where it is determined that there are un-preheated nodes, the server also needs to trigger a preheating retry task for the un-preheated nodes, so as to re-attempt to make the un-preheated nodes execute the preheating task for the target resource through this preheating retry task. Still taking the un-preheated nodes as node e and node f as an example, when the server triggers the preheating retry task, it can update the preheating node information corresponding to the target resource to only indicate that node e and node f are preheating nodes. At this time, only node e and node f send resource pulling requests to the server, and the server will correspondingly feedback the resource location identifier of the target resource. For the resource pulling requests sent by other CDN nodes, the server will not feedback the resource location identifier of the target resource. In this way, once node e and node f send resource pulling requests to the server, they can correspondingly execute the preheating task for the target resource according to the resource location identifier feedback by the server.
[0133] In this way, through the above method, according to the resource cache results feedback by the target access nodes serving as preheating nodes, it is automatically detected whether there are un-preheated nodes among the preheating nodes corresponding to the target resource that have not successfully completed the preheating task for the target resource, and it is controlled to make the un-preheated nodes re-attempt to preheat the target resource, improving the reliability of the preheating task for the target resource.
[0134] To facilitate further understanding of the resource preheating method provided by the embodiments of the present application, the following combines Figure 6 the architecture diagram of the resource preheating system shown in
[0135] As Figure 6 shown, the resource preheating system includes an API (Application Programming Interface) module, a BrokerProxy module, a Redis module, a Result module, a TRP platform, and a TDNS scheduling module.
[0136] Among them, the API module is used to receive the preheating task for the target resource provided by the resource provider; it is also used to obtain the preheating node information corresponding to the target resource provided by the TDNS scheduling module, and the preheating node information includes the IP addresses of the CDN nodes determined by the TDNS scheduling module for executing the preheating task for the target resource; it is also used to control the preheating bandwidth of each access node cluster corresponding to the target resource, that is, according to the bandwidth usage of the access nodes provided by the TDNS scheduling module, configure the corresponding preheating bandwidth for each access node cluster, and accordingly split the target resource to obtain multiple target sub-resources, and determine the resource location identifiers of the multiple target sub-resources.
[0137] The BrokerProxy module is responsible for processing various interface requests, which usually include four interfaces, namely the set interface, the get interface, the post interface, and the query interface. The set interface is responsible for receiving atomic tasks, which can specifically be represented as the resource location identifiers of target sub-resources in the embodiments of this application, and then transferring them to the Redis module for storage; the set interface is also used to receive the IP addresses of each preheating node corresponding to the target resource. The get interface is responsible for forwarding the resource pulling requests sent by the access nodes. The post interface is responsible for forwarding the atomic task results reported by the access nodes, which can also be understood as the resource caching results for the target sub-resources. The query interface is used to forward the atomic task query requests initiated by the resource providers, which can also be understood as the preheating task query requests for the target resources.
[0138] It should be understood that in Figure 6 the system structure shown, the BrokerProxy module closer to the resource provider (i.e., Figure 6 the upper BrokerProxy module in Figure 6 mainly uses the set interface and the query interface, and the BrokerProxy module closer to the CDN nodes (i.e.,
[0139] the lower BrokerProxy module in
[0140] mainly uses the get interface and the post interface.
[0141] The Redis module is responsible for storing the resource location identifiers of the target sub-resources forwarded by the BrokerProxy, as well as the IP addresses of each preheating node corresponding to the target resource; and is used to determine whether the target access node that sends the resource pulling request is a preheating node according to the IP addresses of each preheating node corresponding to the target resource, and when it is determined that it is a preheating node, provide the resource location identifier of the target sub-resource to it accordingly.
[0142] The TDNS scheduling module is used to collect data reported by agents deployed on CDN nodes, such as bandwidth, load, heartbeat data, etc., and receive information provided by manual intervention of resource providers, such as regional indication information, link disabling information, etc. Then, based on the DNS scheduling policy, it determines the warm-up nodes applicable to perform the warm-up task for the target resource, and informs the determined warm-up nodes to the API module through the warm-up node information.
[0143] Figure 6 It also includes an agent module deployed on the CDN node. This agent module is used to collect the operation status information of its own CDN node, such as bandwidth, load, heartbeat data, etc., and report it to the TDNS scheduling module. This agent module is also used to initiate a resource pulling request to the intranet where the resource warm-up system is located to request the target resource to be warmed up.
[0144] Figure 6 When the shown resource warm-up system works specifically, the TDNS scheduling module can receive the operation status information of the CDN nodes reported by each agent, summarize and analyze the received operation status information, and combine the personalized scheduling rules (such as regional indication information, etc.) set by the resource provider to determine the warm-up nodes for performing the warm-up task for the target resource, and send a list including the IP addresses of each warm-up node to the API module. After receiving the URL of the target resource to be warmed up provided by the resource provider and the list of warm-up node IP addresses provided by the TDNS scheduling module, the API module can detect the size of the target resource, and based on the bandwidth usage of each access node cluster, split the target resource to obtain each corresponding multiple target sub-resources, and determine the URL of each target sub-resource. Furthermore, it forwards the URLs of each target sub-resource corresponding to each access node cluster to the BrokerProxy module, thus realizing the batch issuance of atomic tasks. After receiving the atomic task, the BrokerProxy module forwards the atomic task to the Redis module.
[0145] The agent module deployed on the CDN node can periodically send a resource pulling request carrying its own IP address to the intranet. This resource pulling request is transferred to the BrokerProxy module in the intranet through the TRP platform, and the BrokerProxy module further forwards this resource pulling request to the Redis module. The Redis module queries whether the CDN node belongs to the warm-up node corresponding to the target resource; if so, it determines the access node cluster to which the CDN node belongs, and obtains the URL of the target sub-resource corresponding to this access node cluster and feeds it back to the agent module, so that the CDN node to which the agent module belongs can obtain and cache this target sub-resource accordingly, realizing the warm-up of this target sub-resource. After completing the warm-up of this target sub-resource; the agent module can correspondingly feed back the resource caching result to the intranet, so that the Redis module can send the URL of the next target sub-resource to the agent module, enabling the CDN node to which the agent module belongs to execute the warm-up task of the next target sub-resource. At the same time, the Result module will also store and manage the resource caching result fed back by this agent module.
[0146] The resource warm-up mechanism provided by the embodiments of the present application can filter out a large number of CDN nodes that cannot be accessed by users according to the geographical indication information provided by the resource provider and the DNS scheduling policy, avoiding these CDN nodes from performing warm-up tasks. In this way, the number of CDN nodes required to perform warm-up tasks is reduced, and the warm-up bandwidth is also reduced. Through experiments, applying this resource warm-up mechanism to a certain service, the warm-up bandwidth is reduced from 22394.95 Gbps to 16525.62 Gbps, optimized by 26%, greatly reducing the warm-up cost, improving the warm-up efficiency, and avoiding excessive pressure on the network, thus ensuring the stable operation of the entire system. Figure 7 It is a schematic diagram of the experimental results provided by the embodiments of the present application. Figure 7 The first half shows the bandwidth usage when using the existing resource warm-up mechanism, and the second half shows the bandwidth usage when using the resource warm-up mechanism provided by the embodiments of the present application.
[0147] For the resource warm-up method described above, the present application also provides a corresponding resource warm-up device to enable the above resource warm-up method to be applied and implemented in practice.
[0148] See Figure 8 , Figure 8 which is Figure 3 a schematic structural diagram of a resource warm-up device 800 corresponding to the resource warm-up method shown above. As Figure 8 shown, this resource warm-up device 800 includes:
[0149] An acquisition module 801, configured to acquire warm-up node information corresponding to a target resource; the warm-up node information is used to indicate a warm-up node for performing a warm-up task on the target resource, and the warm-up node is determined from among each access node according to the running status information of each access node corresponding to the target resource, and the access node is a content delivery network (CDN) node associated with the domain name to which the target resource belongs;
[0150] A determination module 802, configured to, when receiving a resource pull request sent by a target access node, determine, according to the warm-up node information, whether the target access node is the warm-up node indicated by the warm-up node information;
[0151] A sending module 803, configured to, when it is determined that the target access node is the warm-up node, send a resource location identifier of the target resource to the target access node, so that the target access node acquires and caches the target resource based on the resource location identifier.
[0152] Optionally, the apparatus further includes a node determination module, and the node determination module includes:
[0153] A status information acquisition unit, configured to acquire the running status information of each of the access nodes; the running status information includes at least one of the network condition, load condition, and heartbeat data of the access node;
[0154] A scheduling unit, configured to, based on a domain name system scheduling policy, determine, from among each of the access nodes, a node whose running status meets a preset status condition as the warm-up node according to the running status information of each of the access nodes; the preset status condition is used to measure whether a CDN node is suitable for being accessed by an object.
[0155] Optionally, the node determination module further includes:
[0156] A region information acquisition unit, configured to acquire region indication information corresponding to the target resource; the region indication information is used to indicate the region faced by the target resource;
[0157] Then the scheduling unit is specifically configured to:
[0158] Based on the domain name system scheduling policy and the region indication information, determine, from among each of the access nodes, a node whose running status meets the preset status condition and whose region belongs to the region indicated by the region indication information as the warm-up node according to the running status information and the region to which each of the access nodes belongs.
[0159] Optionally, the region indication information is further used to indicate the priority corresponding to each region faced by the target resource; then the scheduling unit is further used to:
[0160] Determine the priority corresponding to each preheating node according to the priority corresponding to each region indicated by the region indication information and the region to which each of the preheating nodes belongs.
[0161] Optionally, the node determination module further includes:
[0162] A log acquisition unit, configured to acquire the object access logs of each of the access nodes;
[0163] A frequent node determination unit, configured to determine, according to the object access logs of each of the access nodes, frequent access nodes whose access conditions meet a preset access condition among the access nodes; the preset access condition is used to measure whether the access condition of the CDN node meets the preset frequency requirement;
[0164] Then the scheduling unit is specifically configured to:
[0165] Determine, among the access nodes, nodes whose operating status meets the preset status condition and belong to the frequent access nodes as the preheating nodes.
[0166] Optionally, the scheduling unit is further configured to:
[0167] Determine the priority corresponding to each preheating node according to the object access logs of each preheating node; the priority is positively correlated with the access frequency characterized by the object access log.
[0168] Optionally, the sending module 803 is specifically configured to:
[0169] When receiving resource pull requests sent by multiple target access nodes and determining that the multiple target access nodes are all preheating nodes, determine the request response order according to the priorities corresponding to the multiple target access nodes;
[0170] Send the resource location identifier of the target resource to the multiple target access nodes according to the request response order.
[0171] Optionally, the device further includes:
[0172] A preheating bandwidth determination module, configured to determine, for each access node cluster corresponding to the target resource, the preheating bandwidth corresponding to the access node cluster according to the bandwidth usage of the access node cluster; the access node cluster is a CDN node cluster accessed by the domain name to which the target resource belongs, and one access node cluster includes access nodes with the same function;
[0173] A resource slicing module, which is used to slice the target resource for each of the access node clusters based on the preheating bandwidth corresponding to the access node cluster, obtain multiple target sub-resources corresponding to the access node cluster, and determine the resource location identifiers of the multiple target sub-resources respectively.
[0174] Optionally, the sending module 803 is specifically configured to:
[0175] Send the resource location identifier of the i-th target sub-resource to the target access node; the i-th target sub-resource ranks the i-th among the n target sub-resources corresponding to the access node cluster to which the target access node belongs, where i is an integer greater than or equal to 1 and less than or equal to n, and n is an integer greater than 1;
[0176] Receive the resource caching result of the i-th target sub-resource returned by the target access node; the resource caching result is generated by the target access node after completing the preheating task of the i-th target sub-resource based on the resource location identifier of the i-th target sub-resource;
[0177] If i is less than n, send the resource location identifier of the (i + 1)-th target sub-resource to the target access node; if i is equal to n, determine that the target access node has completed the preheating task of the target resource.
[0178] Optionally, the device further includes:
[0179] A receiving module, which is used to receive a preheating task query request for the target resource;
[0180] A query module, which is used to respond to the preheating task query request and determine the execution status of the preheating task corresponding to the target resource according to the currently received resource caching result.
[0181] Optionally, the device further includes:
[0182] A task retry module, which is used to determine whether there is an unpreheated node that has not completed the preheating task of the target resource among the respective preheating nodes corresponding to the target resource according to the received resource caching result when a preset time condition is met; in the case of determining that there is such an unpreheated node, trigger a preheating retry task for the unpreheated node; the preheating retry task is used to make the unpreheated node execute the preheating task of the target resource.
[0183] In the resource preheating device provided in the embodiments of the present application, preheating nodes suitable for preheating the target resource are selected from each access node according to the respective operating status information of each access node corresponding to the target resource in advance; furthermore, only the resource location identifier of the target resource is fed back in response to the resource pulling request sent by the preheating node, and the resource location identifier of the target resource will not be fed back for the resource pulling request sent by the non-preheating node, thereby avoiding all access nodes of the target resource from executing the preheating task for the target resource, reducing the number of CDN nodes executing the preheating task; in the case where the number of CDN nodes executing the preheating task is reduced, the bandwidth resources and storage resources consumed during the execution of the preheating task can be correspondingly reduced, and the preheating efficiency can be improved, and the preheating cost can be reduced.
[0184] The embodiments of the present application also provide a computer device for resource preheating. The computer device may specifically be a terminal device or a server. Hereinafter, the terminal device and the server provided in the embodiments of the present application will be introduced from the perspective of hardware implementation.
[0185] See Figure 9 , Figure 9 is a schematic structural diagram of the terminal device provided in the embodiments of the present application. As Figure 9 shown, for the sake of convenience of description, only the parts related to the embodiments of the present application are shown. For those specific technical details not disclosed, please refer to the method part of the embodiments of the present application. The terminal may be any terminal device including a mobile phone, a tablet computer, a personal digital assistant (PDA), a point of sales (POS), an in-vehicle computer, etc. Taking the terminal as a computer as an example:
[0186] Figure 9 Shown is a block diagram of a part of the structure of a computer related to the terminal provided in the embodiments of the present application. Referring to Figure 9 , the computer includes: a radio frequency (RF) circuit 910, a memory 920, an input unit 930 (including a touch panel 931 and other input devices 932), a display unit 940 (including a display panel 941), a sensor 950, an audio circuit 960 (which may be connected to a speaker 961 and a microphone 962), a wireless fidelity (WiFi) module 970, a processor 980, and a power supply 990, etc. Those skilled in the art can understand that Figure 9 the computer structure shown in
[0187] The memory 920 can be used to store software programs and modules. The processor 980 executes various functional applications and data processing of the computer by running the software programs and modules stored in the memory 920. The memory 920 may mainly include a program storage area and a data storage area. Among them, the program storage area can store the operating system, application programs required for at least one function (such as the sound playback function, the image playback function, etc.); the data storage area can store the data created according to the use of the computer (such as audio data, phone book, etc.). In addition, the memory 920 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0188] The processor 980 is the control center of the computer, connecting various parts of the entire computer through various interfaces and lines. By running or executing the software programs and / or modules stored in the memory 920, and calling the data stored in the memory 920, it executes various functions of the computer and processes data. Optionally, the processor 980 may include one or more processing units; preferably, the processor 980 may integrate an application processor and a modem processor. Among them, the application processor mainly processes the operating system, user interface, and application programs, etc., and the modem processor mainly processes wireless communication. It can be understood that the above modem processor may not be integrated into the processor 980.
[0189] In the embodiment of the present application, the processor 980 included in the terminal is further configured to execute the steps of any one of the resource preheating methods provided in the embodiment of the present application.
[0190] See Figure 10 , Figure 10 FIG. is a schematic structural diagram of a server 1000 provided in an embodiment of the present application. The server 1000 may vary greatly due to configuration or performance differences, and may include one or more central processing units (CPUs) 1022 (for example, one or more processors) and a memory 1032, and one or more storage media 1030 (for example, one or more mass storage devices) for storing application programs 1042 or data 1044. Among them, the memory 1032 and the storage media 1030 may be transient storage or persistent storage. The programs stored in the storage media 1030 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations on the server. Further, the central processor 1022 may be configured to communicate with the storage media 1030 and execute a series of instruction operations in the storage media 1030 on the server 1000.
[0191] Server 1000 may also include one or more power supplies 1026, one or more wired or wireless network interfaces 1050, one or more input / output interfaces 1058, and / or, one or more operating systems, such as Windows Server TM , Mac OS X TM , Unix TM , Linux TM , FreeBSD TM and so on.
[0192] In the above embodiments, the steps performed by the server may be based on the Figure 10 server structure shown.
[0193] Among them, the CPU 1022 may also be used to execute the steps of any implementation manner of the resource preheating method provided in the embodiments of the present application.
[0194] The embodiments of the present application also provide a computer-readable storage medium for storing a computer program, and the computer program is used to execute any implementation manner of the resource preheating method described in the foregoing embodiments.
[0195] The embodiments of the present application also provide a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a computer-readable storage medium. The processor of the computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes any implementation manner of the resource preheating method described in the foregoing embodiments.
[0196] Those skilled in the art can clearly understand that for the convenience and conciseness of description, the specific working processes of the systems, devices, and units described above can refer to the corresponding processes in the foregoing method embodiments, and will not be described in detail here.
[0197] In several embodiments provided by the present application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is only a logical function division, and there may be other division methods in actual implementation. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Another point is that the displayed or discussed mutual coupling or direct coupling or communication connection may be through some interfaces, and the indirect coupling or communication connection of the devices or units may be in an electrical, mechanical, or other form.
[0198] The unit described as a separation component may or may not be physically separated. The component displayed as a unit may or may not be a physical unit, that is, it may be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0199] In addition, each functional unit in various embodiments of the present application may be integrated in a processing unit, may exist physically separately for each unit, or two or more units may be integrated in one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of a software functional unit.
[0200] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present application. The aforementioned storage medium includes: various media that can store computer programs such as USB flash drives, mobile hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical discs.
[0201] It should be understood that in the present application, "at least one (item)" means one or more, and "a plurality" means two or more. "And / or" is used to describe the association relationship of associated objects and indicates that three relationships may exist. For example, "A and / or B" may mean: only A exists, only B exists, and both A and B exist at the same time. Among them, A and B can be singular or plural. The character " / " generally means that the associated objects before and after are in an "or" relationship. "At least one (one)" or a similar expression thereof refers to any combination of these items, including any combination of single item (one) or plural items (ones). For example, at least one (one) of a, b, or c may mean: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0202] As described above, the above embodiments are only used to illustrate the technical solutions of the present application and are not intended to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.
Claims
1. A resource preheating method, characterized in that: The method comprises: Acquire preheating node information corresponding to the target resource; the preheating node information is used to indicate a preheating node that performs a preheating task on the target resource, the preheating node is determined in each access node according to the operation status information of each access node corresponding to the target resource, and the access node is a content delivery network CDN node associated with the domain name to which the target resource belongs; When receiving a resource pull request sent by a target access node, determining, according to the preheating node information, whether the target access node is the preheating node indicated by the preheating node information; In the case where it is determined that the target access node is the preheating node, a resource location identifier of the target resource is sent to the target access node, so that the target access node acquires and caches the target resource based on the resource location identifier.
2. The method according to claim 1, characterized in that The preheating node is determined in the following manner: Acquire the operation status information of each of the access nodes; the operation status information includes at least one of the network status, load status and heartbeat data of the access node; Based on the domain name system scheduling strategy, according to the respective operating status information of each of the access nodes, a node whose operating status meets a preset status condition is determined among the access nodes as the preheating node; The preset status condition is used to measure whether the CDN node is suitable for being accessed by the object.
3. The method according to claim 2, characterized in that The method further comprises: Acquire region indication information corresponding to the target resource; the region indication information is used to indicate the region to which the target resource is directed; The method of determining, based on the domain name system scheduling strategy and according to the respective operating status information of each of the access nodes, a node whose operating status satisfies a preset status condition among the access nodes as the preheating node includes: Based on the domain name system scheduling strategy and the regional indication information, and according to the operating status information and the region to which each of the access nodes belongs, a node whose operating status meets the preset status condition and whose region is the region indicated by the regional indication information is determined among the access nodes as the preheating node.
4. The method according to claim 3, characterized in that The region indication information is also used to indicate the priority corresponding to each region to which the target resource is directed; the method further includes: The priorities corresponding to the respective regions indicated by the region indication information and the regions to which the respective preheating nodes belong are determined.
5. The method according to claim 2, characterized in that: The method further comprises: Obtaining the object access log of each of the access nodes; According to the object access logs of the respective access nodes, a frequently accessed node whose access condition meets a preset access condition is determined in each access node; the preset access condition is used to measure whether the access condition of the CDN node meets a preset frequency requirement; The step of determining, from among the access nodes, a node whose operating state satisfies a preset state condition as the preheating node comprises: A node whose running status satisfies the preset status condition and is a frequently visited node is determined among the access nodes as the preheating node.
6. The method according to claim 5, characterized in that The method further comprises: According to the object access log of each of the preheating nodes, the priority corresponding to each of the preheating nodes is determined; the priority is positively correlated with the access frequency represented by the object access log.
7. The method according to claim 4 or 6, characterized in that: The sending the resource location identifier of the target resource to the target access node includes: When receiving resource pull requests sent by multiple target access nodes and determining that the multiple target access nodes are all preheated nodes, determining a request response order according to respective priorities corresponding to the multiple target access nodes; The resource location identifier of the target resource is sent to the multiple target access nodes according to the request response order.
8. The method according to claim 1, characterized in that The method further comprises: For each access node cluster corresponding to the target resource, determine the preheating bandwidth corresponding to the access node cluster according to the bandwidth usage of the access node cluster; the access node cluster is a CDN node cluster accessed by the domain name to which the target resource belongs, and one access node cluster includes the access nodes having the same function; For each of the access node clusters, the target resource is segmented based on the preheating bandwidth corresponding to the access node cluster to obtain a plurality of target sub-resources corresponding to the access node cluster, and resource location identifiers of each of the plurality of target sub-resources are determined.
9. The method according to claim 8, characterized in that The sending the resource location identifier of the target resource to the target access node includes: Sending a resource location identifier of the i-th target sub-resource to the target access node; the i-th target sub-resource ranks i-th among n target sub-resources corresponding to the access node cluster to which the target access node belongs, where i is an integer greater than or equal to 1 and less than or equal to n, and n is an integer greater than 1; receiving a resource cache result of the i-th target sub-resource returned by the target access node; the resource cache result is generated by the target access node after completing a preheating task for the i-th target sub-resource based on the resource location identifier of the i-th target sub-resource; If i is less than n, the resource location identifier of the i+1th target sub-resource is sent to the target access node; if i is equal to n, it is determined that the target access node completes the preheating task for the target resource.
10. The method according to claim 9, characterized in that The method further comprises: Receiving a preheating task query request for the target resource; In response to the preheating task query request, the execution status of the preheating task corresponding to the target resource is determined according to the currently received resource cache result.
11. The method according to claim 9, characterized in that The method further comprises: When the preset time condition is met, determining, according to the received resource cache result, whether there is an unpreheated node that has not completed the preheating task for the target resource among the preheating nodes corresponding to the target resource; In the case where it is determined that the non-preheated node exists, a preheating retry task for the non-preheated node is triggered; the preheating retry task is used to enable the non-preheated node to perform the preheating task for the target resource.
12. A resource preheating device, characterized in that: The device comprises: An acquisition module, used to acquire preheating node information corresponding to a target resource; the preheating node information is used to indicate a preheating node that performs a preheating task on the target resource, the preheating node is determined in each access node according to operation status information of each access node corresponding to the target resource, and the access node is a content delivery network CDN node associated with a domain name to which the target resource belongs; A determination module, configured to determine, when receiving a resource pull request sent by a target access node, whether the target access node is the preheating node indicated by the preheating node information according to the preheating node information; The sending module is used to send the resource location identifier of the target resource to the target access node when it is determined that the target access node is the preheating node, so that the target access node obtains and caches the target resource based on the resource location identifier.
13. A computer device, characterized in that: The device includes a processor and a memory; The memory is used to store computer programs; The processor is used to execute the resource preheating method according to any one of claims 1 to 11 according to the computer program.
14. A computer-readable storage medium, characterized in that: The computer-readable storage medium is used to store a computer program, and the computer program is used to execute the resource preheating method according to any one of claims 1 to 11.
15. A computer program product, comprising a computer program or instructions, characterized in that: When the computer program or the instruction is executed by a processor, the resource preheating method according to any one of claims 1 to 11 is implemented.
Citation Information
Cited By
Preheating method, device, equipment and system for model file
CN120596448A