Resource request processing method, device, computer equipment, readable storage medium and program product

By identifying and distributing hotspot resources to other cache servers within the CDN cluster, the problem of excessive cache server load is solved, the efficiency and reliability of CDN services are improved, server performance loss is reduced, and network bandwidth is saved.

CN119544795BActive Publication Date: 2025-09-30CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411716997.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-27
Publication Date
2025-09-30
Estimated Expiration
2044-11-27

AI Technical Summary

Technical Problem

In CDN services, some cache servers are overloaded, resulting in degraded service quality and even cache breakdown, which directly puts huge pressure on the original data source.

Method used

The backend cache server responds to resource requests, counts request load data, identifies hot resources, and distributes them to other cache servers in the cluster. The gateway is used to disperse resource requests to these cache servers for processing, and multicast transmission strategies and double verification mechanisms are used to ensure the consistency and integrity of resource distribution.

Benefits of technology

It achieves balanced diffusion of hotspot request pressure, reduces the performance loss of cache servers, improves the efficiency and reliability of CDN services, reduces the amount of back-to-source traffic, and saves network bandwidth costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119544795B_ABST
    Figure CN119544795B_ABST
Patent Text Reader

Abstract

The present application relates to a resource request processing method, apparatus, computer equipment, computer-readable storage medium, and computer program product. The method is applied to the first cache server in the cluster, and the method includes: in response to receiving a resource request forwarded by a gateway, extracting the first identification information of the resource carried by the resource request, and updating the request load data corresponding to the first identification information; when the request load data is greater than a preset threshold, determining the resource as a hotspot resource, and adding second identification information to the resource request; sending the hotspot resource to the second cache server other than the first cache server in the cluster, and returning the resource request carrying the second identification information to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information. The use of this method can improve the access quality of CDN services.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of content distribution networks, and in particular to a resource request processing method, apparatus, computer equipment, computer-readable storage medium, and computer program product. Background Art

[0002] Content Delivery Network (CDN) uses servers distributed around the world to store static website content (such as images, web pages, videos, and audio). It supports selecting the appropriate server based on the user's location. When users access a website, they can obtain pre-cached resources from the nearest server without going through multiple routers. This can effectively improve access speed and is therefore becoming increasingly widely used.

[0003] CDN edge nodes often face a large number of resource requests. When a user accesses an edge node, if the required resource is not cached, the edge node requests the resource from a higher-level node or the original data source and caches it. Resource requests are typically forwarded by the CDN gateway, which uses a consistent hashing algorithm to process the URL (Uniform Resource Locator) and forward the resource request to the appropriate cache server. However, some cache servers are currently overloaded, affecting CDN service quality. Some even experience cache failure, causing a large number of resource requests to be directly returned to the original data source, placing significant pressure on the original data source. Summary of the Invention

[0004] Based on this, it is necessary to provide a resource request processing method, apparatus, computer equipment, computer-readable storage medium and computer program product that can improve the access quality of CDN services in response to the above technical problems.

[0005] In a first aspect, the present application provides a resource request processing method, applied to a first cache server in a cluster, the method comprising:

[0006] In response to receiving a resource request forwarded by the gateway, extracting first identification information of the resource carried in the resource request, and updating request payload data corresponding to the first identification information;

[0007] In a case where the request load data is greater than a preset threshold, determining the resource as a hotspot resource and adding second identification information to the resource request;

[0008] The hotspot resource is sent to a second cache server other than the first cache server in the cluster, and the resource request carrying the second identification information is transmitted back to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information.

[0009] In one embodiment, sending the hotspot resource to a second cache server other than the first cache server in the cluster includes:

[0010] Based on the hotspot resource, a message in a preset format is generated; the message includes the hotspot resource and metadata of the hotspot resource;

[0011] The message is sent to a second cache server other than the first cache server in the cluster, so that the second cache server verifies the message based on the preset format and obtains a verification result for the message; the verification result includes a first verification result of the metadata of the hotspot resource and a second verification result of the hotspot resource.

[0012] In one embodiment, after sending the message to a second cache server other than the first cache server in the cluster, the method further includes:

[0013] In response to receiving a first request sent by the second cache server, resending the metadata of the hotspot resource to the second cache server; the first request is sent by the second cache server when the first verification result is failed;

[0014] In response to receiving a second request sent by the second cache server, resending the hotspot resource to the second cache server; the second request is sent by the second cache server when the second verification result is failure.

[0015] In one embodiment, sending the hotspot resource to a second cache server other than the first cache server in the cluster includes:

[0016] In a case where the hotspot resource does not correspond to the third identification information, the corresponding third identification information is added to the hotspot resource, and the hotspot resource is sent to a second cache server other than the first cache server in the cluster.

[0017] In one embodiment, the request load data includes at least a request frequency and an amount of resources required for the request, and when the request load data is greater than a preset threshold, determining the resource as a hot resource includes:

[0018] In a case where the request frequency is greater than a first preset threshold and / or the amount of resources required by the request is greater than a second preset threshold, the resource is determined as a hotspot resource.

[0019] In one embodiment, sending the hotspot resource to a second cache server other than the first cache server in the cluster includes:

[0020] The hotspot resource is sent to the second cache server in the cluster except the first cache server in a multicast manner.

[0021] In a second aspect, the present application further provides a resource request processing device, applied to a first cache server in a cluster, the device comprising:

[0022] a load data updating module, configured to, in response to receiving a resource request forwarded by the gateway, extract first identification information of the resource carried in the resource request, and update the request load data corresponding to the first identification information;

[0023] a hot resource determining module, configured to determine the resource as a hot resource when the request load data is greater than a preset threshold, and add second identification information to the resource request;

[0024] A resource request forwarding module is used to send the hotspot resource to a second cache server other than the first cache server in the cluster, and to transmit the resource request carrying the second identification information back to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information.

[0025] In a third aspect, the present application further provides a computer device comprising a memory and a processor, wherein the memory stores a computer program, and the processor implements the steps of any of the above methods when executing the computer program.

[0026] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which implements the steps of any of the above-described methods when the computer program is executed by a processor.

[0027] In a fifth aspect, the present application also provides a computer program product, comprising a computer program, which implements the steps of any of the above methods when executed by a processor.

[0028] The above-mentioned resource request processing method, device, computer equipment, computer-readable storage medium and computer program product can identify hotspot resources by responding to resource requests through the back-end cache server and counting the request load corresponding to each resource; by distributing hotspot resources to other cache servers in the cluster and instructing the gateway to disperse resource requests for accessing hotspot resources to other cache servers, it is possible to achieve balanced diffusion of the pressure of hotspot requests, reduce the performance loss of the cache server, fully utilize server resources, and improve the efficiency and reliability of CDN services. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the following briefly introduces the drawings required for use in the embodiments of the present application or related technical descriptions. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying any creative work.

[0030] Figure 1 A diagram illustrating an application environment of a resource request processing method in one embodiment;

[0031] Figure 2 1 is a flow chart of a resource request processing method in one embodiment;

[0032] Figure 3 A flowchart of the steps of sending a hotspot resource to a second cache server other than the first cache server in a cluster in one embodiment;

[0033] Figure 4 is a flowchart of a resource request processing method in another embodiment;

[0034] Figure 5 is a structural block diagram of a resource request processing device in one embodiment;

[0035] Figure 6 FIG. 1 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0036] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.

[0037] The resource request processing method provided in the embodiment of the present application can be applied to Figure 1In the application environment shown in the figure, CDN includes a group of cache server clusters. Cache Server (CS) is a technology that stores frequently accessed data in memory or disk to improve content access speed, reduce the number of visits to the original data source, and improve system performance. Currently, in order to improve the cache hit rate of edge nodes and reduce back-to-source and network congestion, the same resource is usually distributed to the same cache server. Users can access the resource through the terminal ( Figure 1 104). A first cache server 104 in the cluster stores the resource requested. Gateway 102 then forwards the resource request to first cache server 104. In response to receiving the resource request forwarded by gateway 102, first cache server 104 can extract first identification information of the resource carried in the resource request and update the request payload corresponding to the first identification information. If the request payload exceeds a preset threshold, first cache server 104 can determine the resource as a hotspot resource and add second identification information to the resource request. Furthermore, first cache server 104 can send the hotspot resource to a second cache server 106 in the cluster other than first cache server 104 and return the resource request carrying the second identification information to gateway 102. For example, first cache server 104 can include a hotspot component and a distribution component. The hotspot component can be used to identify hotspot resources, and the distribution component can be used to distribute the hotspot resources to second cache servers 106 in the cluster other than first cache server 104. At this point, second cache server 106 stores the resource requested. Gateway 102 can forward the resource request to second cache server 106 for processing based on the second identification information. Terminals may include, but are not limited to, various personal computers, laptops, smartphones, tablets, IoT devices, and portable wearable devices. IoT devices may include smart speakers, smart TVs, smart air conditioners, smart car devices, and projectors. Portable wearable devices may include smart watches, smart bracelets, and head-mounted devices. Head-mounted devices may include virtual reality (VR) devices, augmented reality (AR) devices, smart glasses, and the like. The first cache server 104 and the second cache server 106 may be independent physical servers.

[0038] In an exemplary embodiment, Figure 2 As shown, a resource request processing method is provided, which is applied to Figure 1 Taking the first cache server 104 in FIG. 1 as an example, the method includes the following steps S202 to S206. In which:

[0039] Step S202: In response to receiving the resource request forwarded by the gateway, extract the first identification information of the resource carried in the resource request, and update the request payload data corresponding to the first identification information.

[0040] Exemplarily, the gateway may receive a resource request sent by a user and forward it to the first cache server 104 within the cluster. When the first cache server 104 receives the resource request, it may parse the resource request, extract the first identification information carried by the resource request, and determine the load (e.g., network load, computing load, storage load, etc.) caused by the resource request on the first cache server 104, and update the request load data corresponding to the first identification information. The first identification information may be a cache key, which may correspond one-to-one to a cache resource and be used to uniquely identify the cache resource. The cache resource may be a pre-stored file. Specifically, the first cache server 104 may update the obtained cache key and load-related information to an information statistics medium. The information statistics medium may be composed of a hash object storage table, which may contain key information cache keys of resource requests and corresponding statistical data on the request load.

[0041] Step S204: When the request load data is greater than a preset threshold, the resource is determined as a hotspot resource, and second identification information is added to the resource request.

[0042] For example, multiple request load data may correspond to multiple preset thresholds. The first cache server 104 may perform a determination based on a pre-set threshold mechanism. When one or more request load data are greater than a predetermined threshold, the first cache server 104 may determine that the resource is a hotspot resource and add second identification information to the resource request for accessing the hotspot resource. The second identification information may be a response header identifier.

[0043] Step S206: Send the hotspot resource to a second cache server other than the first cache server in the cluster, and return the resource request carrying the second identification information to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information.

[0044] For example, the first cache server 104 can package the hotspot resources and distribute them to all other cache servers (second cache servers) in the cluster. Furthermore, the gateway can identify resource requests carrying the second identification information as being for accessing hotspot resources and use a round-robin algorithm to spread these resource requests to each second cache server.

[0045] In the above-mentioned resource request processing method, hotspot resources can be identified by the back-end cache server responding to resource requests and counting the request load corresponding to each resource; by distributing hotspot resources to other cache servers in the cluster and instructing the gateway to disperse resource requests for accessing hotspot resources to other cache servers, the pressure of hotspot requests can be evenly distributed, the performance loss of the cache server can be reduced, the server resources can be fully utilized, and the efficiency and reliability of CDN services can be improved.

[0046] It can evenly distribute the pressure of hot spot requests to different machines, fully utilize server resources, reduce the amount of back-to-source requests, thereby improving CDN service quality and saving network bandwidth costs.

[0047] In an exemplary embodiment, Figure 3 As shown, the step of sending the hotspot resource to the second cache server other than the first cache server in the cluster may include:

[0048] Step A1: Generate a message in a preset format based on the hotspot resource; the message includes the hotspot resource and metadata of the hotspot resource.

[0049] Illustratively, a message in a preset format may include a first packet and a non-first packet. The first packet may consist of a 16-byte data transmission ID (e.g., a multicast ID), a 1-byte packet type flag set to 1, and other file metadata. File metadata may include the file name and size. Non-first packets may consist of a 16-byte data transmission ID, a 1-byte packet type flag set to 2, a 4-byte file offset, a 2-byte data length, and other file content.

[0050] Step A2, sending a message to the second cache server in the cluster except the first cache server, so that the second cache server verifies the message based on a preset format and obtains a verification result for the message; the verification result includes a first verification result of the metadata of the hotspot resource and a second verification result of the hotspot resource.

[0051] For example, after receiving the message, the second cache server may first determine whether the message is missing metadata of the hotspot resource to obtain a first verification result. The first verification result may include a pass / fail. Then, when it is determined that the metadata of the hotspot resource is not missing, the second cache server may determine whether the message is missing the hotspot resource to obtain a second verification result. The second verification result may include a pass / fail. In one possible implementation, the first verification result and the second verification result may be used to determine the second cache server for processing the resource request carrying the second identification information.

[0052] In this embodiment, by dual verification of hotspot resource metadata and content, the consistency of hotspot resource distribution can be improved, message duplication and disorder can be avoided, and the consistency and integrity of hotspot resource distribution can be ensured.

[0053] Furthermore, if Figure 4 As shown, the resource request processing method may further include:

[0054] Step S2071: in response to receiving a first request sent by the second cache server, resend metadata of the hotspot resource to the second cache server; the first request is sent by the second cache server when the first verification result is failed.

[0055] Step S2072: in response to receiving a second request sent by the second cache server, resend the hotspot resource to the second cache server; the second request is sent by the second cache server when the second verification result is failure.

[0056] Exemplarily, if the second cache server determines that the metadata of the hotspot resource is missing, it can request the metadata of the hotspot resource from the data transmission source address (e.g., the multicast source address); if it determines that the metadata of the hotspot resource is not missing, it can determine whether the message is missing the hotspot resource. If it determines that the hotspot resource is missing, it can request the missing portion of the hotspot resource from the data transmission source address; if it determines that the hotspot resource is not missing, it can cache the hotspot file. In one possible implementation, if it determines that the file content is missing, the second cache server can use a Range request to request the missing portion from the multicast source address.

[0057] In this embodiment, by setting up a retransmission mechanism to promptly detect and reacquire missing hotspot resources or metadata of hotspot resources, the risk of content access failure due to data loss can be reduced. For example, multicast based on the UDP protocol is avoided, which has no error correction mechanism and may cause packet loss or file inconsistency during transmission.

[0058] In an exemplary embodiment, the step of sending the hotspot resource to a second cache server other than the first cache server in the cluster may include:

[0059] Step B1: If the hotspot resource does not correspond to the third identification information, add the corresponding third identification information to the hotspot resource, and send the hotspot resource to the second cache server in the cluster except the first cache server.

[0060] Among them, the fact that the hotspot resource does not correspond to the third identification information can be used to characterize that the hotspot resource has not been diffused. Exemplarily, the correspondence between the hotspot resource and the third identification information can be stored in the first cache server 104 and the second cache server that receives the hotspot resource. In a possible implementation, the first cache server 104 can query the cache list according to the cache key carried by the resource request, and extract the identification header information related to the resource request to determine whether the requested hotspot resource has been multicast. For example, the file identifier can be used to determine whether it is a multicast file, and a file identifier of 1 can be used to characterize that the file has been multicast. If so, a response header is added to identify the request as a hotspot file, and the file content is responded to the gateway at the same time. If not, the file is multicast, and the multicast identification information is written into the cache of the file, and the hotspot file response header identifier is added when responding to the file to the gateway.

[0061] In this embodiment, by monitoring the diffusion status of hotspot resources, it is possible to accurately track the processing status of each hotspot resource, thereby avoiding repeated resource transmission.

[0062] In an exemplary embodiment, the request load data includes at least the request frequency and the amount of resources required by the request. When the request load data is greater than a preset threshold, the step of determining the resource as a hot resource may include:

[0063] Step C1: When the request frequency is greater than a first preset threshold and / or the amount of resources required by the request is greater than a second preset threshold, the resource is determined as a hotspot resource.

[0064] For example, first cache server 104 can parse a resource request to extract the CTL-STORT-URL field (cache key), the CONTENT-LENGTH field, and the number of requests. The number of requests is accumulated using the cache key and stored in a hash table. Specifically, the cache key is used as the key value, and the number of requests per unit time for the cache key is used as the value. The CONTENT-LENGTH field is accumulated using the cache key and stored in the hash table. Specifically, the CONTENT-LENGTH field is used to calculate the request bandwidth per unit time.

[0065] In this embodiment, by adopting a dual-threshold comparison method, a hot resource identification mechanism for large files and high QPS (Queries Per Second) can be implemented. In high concurrency and high QPS scenarios, hot resources can be identified in advance for diffusion, reducing response delays caused by server overload.

[0066] In an exemplary embodiment, the step of sending the hotspot resource to a second cache server other than the first cache server in the cluster may include:

[0067] Step D1: Send the hotspot resource to the second cache server in the cluster except the first cache server in a multicast manner.

[0068] Exemplarily, a message in a preset format can be generated based on hotspot resources; the message includes the hotspot resources and metadata of the hotspot resources; when the hotspot resources do not correspond to the third identification information, the message is sent to the second cache server in the cluster except the first cache server in a multicast manner, and the corresponding third identification information is added for the hotspot resources.

[0069] Multicast is a network communication mode used for one-to-many data transmission. A multicast network for a multicast group is typically divided into three parts: the multicast source, the multicast router, and the multicast members. The multicast source, the sender of information, can send data to multiple multicast members simultaneously. In a multicast mode, data packets can be transmitted to multiple recipients (for example, a secondary cache server) simultaneously, without establishing a separate connection for each recipient. In a multicast, the sender only needs to send one copy of the data packet, and the network replicates and transmits it to all recipients. Transmitting multiple copies of the same data through multicast ensures that messages only need to be delivered once on each network link, and messages are only replicated if a link forks, significantly reducing server load and network bandwidth resources. Multicast messages are sent on demand, reducing redundant network traffic while ensuring a certain level of data security.

[0070] In this embodiment, by adopting a multicast transmission strategy, hotspot resources are distributed from the first cache server to all other cache servers in the cluster, which can achieve one-to-many efficient data distribution, reduce the waste of multi-link bandwidth, and effectively reduce network load.

[0071] To sum up, in the above-mentioned resource request processing method, hotspot resources can be identified by the back-end cache server responding to resource requests and counting the request load corresponding to each resource; by distributing hotspot resources to other cache servers in the cluster and instructing the gateway to disperse resource requests for accessing hotspot resources to other cache servers, the pressure of hotspot requests can be evenly distributed, the performance loss of the cache server can be reduced, the server resources can be fully utilized, and the efficiency and reliability of CDN services can be improved.

[0072] It should be understood that, although the various steps in the flowcharts involved in the various embodiments described above are displayed in sequence according to the instructions of the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and these steps can be executed in other orders. Moreover, at least a portion of the steps in the flowcharts involved in the various embodiments described above can include multiple steps or multiple stages, and these steps or stages are not necessarily executed and completed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a portion of steps or stages in other steps.

[0073] Based on the same inventive concept, embodiments of the present application also provide a resource request processing device for implementing the resource request processing method described above. The solution provided by this device is similar to the solution described in the method described above. Therefore, the specific limitations of one or more resource request processing device embodiments provided below can be found in the above-described limitations of the resource request processing method and will not be further elaborated here.

[0074] In an exemplary embodiment, Figure 5 As shown, a resource request processing device 300 is provided, comprising: a load data updating module 301, a hot resource determining module 302 and a resource request forwarding module 303, wherein:

[0075] The load data updating module 301 is configured to extract the first identification information of the resource carried in the resource request in response to receiving the resource request forwarded by the gateway, and update the request load data corresponding to the first identification information.

[0076] The hot resource determining module 302 is configured to determine a resource as a hot resource when the request load data is greater than a preset threshold, and to add second identification information to the resource request.

[0077] The resource request forwarding module 303 is used to send hot resources to the second cache server other than the first cache server in the cluster, and return the resource request carrying the second identification information to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information.

[0078] In an exemplary embodiment, the resource request forwarding module 303 is further configured to:

[0079] Generate a message in a preset format based on the hotspot resource; the message includes the hotspot resource and its metadata;

[0080] A message is sent to a second cache server other than the first cache server in the cluster, so that the second cache server verifies the message based on a preset format and obtains a verification result for the message; the verification result includes a first verification result of the metadata of the hotspot resource and a second verification result of the hotspot resource.

[0081] In an exemplary embodiment, the resource request processing apparatus 300 further includes:

[0082] The hotspot resource verification module is used to resend the metadata of the hotspot resource to the second cache server in response to receiving a first request sent by the second cache server; the first request is sent by the second cache server when the first verification result is failed.

[0083] The hotspot resource verification module is further configured to resend the hotspot resource to the second cache server in response to receiving a second request sent by the second cache server; the second request is sent by the second cache server when the second verification result is failed.

[0084] In an exemplary embodiment, the resource request forwarding module 303 is further configured to:

[0085] In the case that the hotspot resource does not correspond to the third identification information, the corresponding third identification information is added to the hotspot resource, and the hotspot resource is sent to the second cache server in the cluster except the first cache server.

[0086] In an exemplary embodiment, the request load data includes at least the request frequency and the amount of resources required by the request. The hot resource determination module 302 is further configured to:

[0087] When the request frequency is greater than a first preset threshold and / or the amount of resources required by the request is greater than a second preset threshold, the resource is determined as a hot resource.

[0088] In an exemplary embodiment, the resource request forwarding module 303 is further configured to:

[0089] The hotspot resource is sent to the second cache server in the cluster except the first cache server in a multicast manner.

[0090] Each module in the resource request processing apparatus described above may be implemented in whole or in part through software, hardware, or a combination thereof. Each module may be embedded in or independent of a processor in a computer device in the form of hardware, or may be stored in a memory in the computer device in the form of software, so that the processor can call and execute the corresponding operations of each module.

[0091] In an exemplary embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as shown in FIG. Figure 6 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, abbreviated as I / O) and a communication interface. The processor, memory and input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and computer program in the non-volatile storage medium. The database of the computer device is used to store cache resources. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a resource request processing method is implemented.

[0092] Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.

[0093] In an exemplary embodiment, a computer device is provided, including a memory and a processor. The memory stores a computer program, and the processor implements the steps in the above method embodiments when executing the computer program.

[0094] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.

[0095] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.

[0096] Those skilled in the art will understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. In particular, any reference to memory, database, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The databases involved in the various embodiments provided herein may include at least one of a relational database and a non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the various embodiments provided herein may be, but are not limited to, general-purpose processors, central processing units (CPUs), graphics processing units (GPUs), digital signal processors (DSPs), programmable logic devices (PLDs), quantum computing-based data processing logic devices, artificial intelligence (AI) processors, and the like.

[0097] The technical features of the above embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0098] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be determined by the appended claims.

Claims

1. A resource request processing method, characterized in that: Applied to a first cache server in a cluster, the method includes: In response to receiving a resource request forwarded by the gateway, extracting first identification information of the resource carried in the resource request, and updating request payload data corresponding to the first identification information; In a case where the request load data is greater than a preset threshold, determining the resource as a hotspot resource and adding second identification information to the resource request; Sending the hotspot resource to a second cache server other than the first cache server in the cluster, and returning the resource request carrying the second identification information to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information; The sending of the hotspot resource to a second cache server other than the first cache server in the cluster includes: Based on the hotspot resource, a message in a preset format is generated; the message includes the hotspot resource and metadata of the hotspot resource; The message is sent to a second cache server other than the first cache server in the cluster, so that the second cache server verifies the message based on the preset format and obtains a verification result for the message; the verification result includes a first verification result of the metadata of the hotspot resource and a second verification result of the hotspot resource.

2. The method according to claim 1, characterized in that After sending the message to a second cache server other than the first cache server in the cluster, the method further comprises: In response to receiving a first request sent by the second cache server, resending the metadata of the hotspot resource to the second cache server; the first request is sent by the second cache server when the first verification result is failed; In response to receiving a second request sent by the second cache server, resending the hotspot resource to the second cache server; the second request is sent by the second cache server when the second verification result is failure.

3. The method according to claim 1, characterized in that The sending the hotspot resource to a second cache server other than the first cache server in the cluster includes: When the hotspot resource does not correspond to the third identification information, the corresponding third identification information is added to the hotspot resource, and the hotspot resource is sent to the second cache server in the cluster except the first cache server. The third identification information is used to indicate that the hotspot resource has not been diffused.

4. The method according to claim 1, wherein The request load data includes at least a request frequency and an amount of resources required by the request, and when the request load data is greater than a preset threshold, determining the resource as a hot resource includes: In a case where the request frequency is greater than a first preset threshold and / or the amount of resources required by the request is greater than a second preset threshold, the resource is determined as a hotspot resource.

5. The method according to any one of claims 1 to 4, characterized in that The sending the hotspot resource to a second cache server other than the first cache server in the cluster includes: The hotspot resource is sent to the second cache server in the cluster except the first cache server in a multicast manner.

6. A resource request processing device, characterized in that: Applied to a first cache server in a cluster, the device comprises: a load data updating module, configured to, in response to receiving a resource request forwarded by the gateway, extract first identification information of the resource carried in the resource request, and update the request load data corresponding to the first identification information; a hot resource determining module, configured to determine the resource as a hot resource when the request load data is greater than a preset threshold, and add second identification information to the resource request; a resource request forwarding module, configured to send the hotspot resource to a second cache server other than the first cache server in the cluster, and transmit the resource request carrying the second identification information back to the gateway, so that the gateway forwards the resource request to the second cache server for processing based on the second identification information; The resource request forwarding module is further used to generate a message in a preset format based on the hotspot resource; the message includes the hotspot resource and metadata of the hotspot resource; The resource request forwarding module is also used to send a message to a second cache server in the cluster other than the first cache server, so that the second cache server verifies the message based on a preset format and obtains a verification result for the message; the verification result includes a first verification result of the metadata of the hotspot resource and a second verification result of the hotspot resource.

7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 5 are implemented.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.

9. A computer program product comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.