Method and device for scheduling network resource requests when network resource requests increase suddenly
By detecting and redirecting network resource requests, it solves the problem of CDN cache server bandwidth overload and ensures service quality when network resource requests suddenly increase.
Patent Information
- Application Number
- CN202210762776.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-29
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2042-06-29
AI Technical Summary
When network resource requests suddenly increase, the bandwidth of the CDN cache server is easily filled up by burst traffic, affecting service quality.
By detecting the network bandwidth usage, if it is higher than or equal to the preset threshold, redirect the request to the CDN cache server whose bandwidth usage is lower than the threshold to avoid bandwidth overload of a single server.
In extreme situations where network resource requests suddenly increase, ensure that the bandwidth of the CDN cache server is not filled up to ensure service quality.
Smart Images

Figure CN115190180B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of data transmission, and in particular to a method and device for scheduling network resource requests when network resource requests increase suddenly. Background Art
[0002] Content Delivery Network (CDN) is a layer of intelligent virtual network built on the existing Internet. By deploying CDN cache servers throughout the network, the source site content is distributed to all CDN cache servers, allowing users to obtain the required content nearby.
[0003] Currently, CDN scheduling equipment will find a suitable CDN cache server for users to send network resources to users. Specifically, the client will send a network resource request to the determined CDN cache server, and the CDN cache server will return the corresponding network resource. However, if the CDN cache server receives too many network resource requests within a certain period of time, the bandwidth of the CDN cache server will be filled up by the burst traffic, thus affecting the service quality. Summary of the invention
[0004] The present disclosure provides a method and device for scheduling network resource requests when network resource requests increase suddenly, which can ensure that the network bandwidth of the CDN cache server will not be fully utilized in the extreme case of a sudden increase in network resource requests, thereby ensuring the CDN service quality.
[0005] In a first aspect, an embodiment of the present disclosure provides a method for scheduling network resource requests when network resource requests increase suddenly, the method being applied to a CDN cache server, comprising:
[0006] Detect network bandwidth usage;
[0007] If it is detected that the network bandwidth usage is higher than or equal to the preset network bandwidth usage threshold, the received network resource request is redirected to a CDN cache server in the CDN node to which the network bandwidth usage is lower than the preset network bandwidth usage threshold.
[0008] In some implementations of the first aspect, detecting network bandwidth usage includes:
[0009] Detect network bandwidth usage in real time.
[0010] In some implementations of the first aspect, the network bandwidth occupancy of other CDN cache servers in the CDN node is obtained from a CDN scheduling device.
[0011] In some implementations of the first aspect, each CDN cache server in the CDN node to which the CDN cache server belongs is respectively configured with a corresponding preset network bandwidth occupation threshold.
[0012] In some implementations of the first aspect, if it is detected that the network bandwidth usage is higher than or equal to a preset network bandwidth usage threshold, redirecting the received network resource request to a CDN cache server whose network bandwidth usage is lower than the preset network bandwidth usage threshold in the CDN node to which it belongs includes:
[0013] If it is detected that the network bandwidth usage is higher than or equal to the preset network bandwidth usage threshold, a CDN cache server that meets the preset conditions is selected from the CDN cache servers whose network bandwidth usage is lower than the preset network bandwidth usage threshold in the CDN nodes;
[0014] A redirection instruction is sent to the user terminal that sends the network resource request, so that the user terminal sends the network resource request to the selected CDN cache server according to the redirection instruction.
[0015] In some implementations of the first aspect, the method further includes:
[0016] A redirection record of the network resource request is sent to the CDN scheduling device, informing the CDN scheduling device to stop allocating network resource requests to the CDN cache server until the network bandwidth usage uploaded by the CDN cache server is lower than the preset network bandwidth usage threshold.
[0017] In some implementations of the first aspect, the method further includes:
[0018] If the network bandwidth usage of other CDN cache servers in the CDN node is higher than or equal to the preset network bandwidth usage threshold, the received network resource request is redirected to the CDN cache server in the corresponding backup node.
[0019] In a second aspect, an embodiment of the present disclosure provides a network resource request scheduling device when network resource requests increase suddenly, the device is applied to a CDN cache server, and includes:
[0020] A detection module, used to detect network bandwidth usage;
[0021] The redirection module is used to redirect the received network resource request to a CDN cache server whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in the CDN node to which it belongs if it detects that the network bandwidth occupancy is higher than or equal to the preset network bandwidth occupancy threshold.
[0022] In a third aspect, an embodiment of the present disclosure provides an electronic device, comprising: at least one processor; and a memory communicatively connected to the at least one processor; the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to execute the method described above.
[0023] In a fourth aspect, an embodiment of the present disclosure provides a non-transitory computer-readable storage medium storing computer instructions, where the computer instructions are used to cause a computer to execute the method described above.
[0024] In the present disclosure, the CDN cache server can detect its own network bandwidth occupancy. If it detects that its own network bandwidth occupancy is higher than or equal to a preset network bandwidth occupancy threshold, it will redirect the received network resource request to a CDN cache server whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in its CDN node. In this way, in the extreme case of a sudden increase in network resource requests, it can ensure that the network bandwidth of the CDN cache server will not be fully utilized, thereby ensuring the quality of CDN service.
[0025] It should be understood that the contents described in the summary of the invention are not intended to limit the key or important features of the embodiments of the present disclosure, nor are they intended to limit the scope of the present disclosure. Other features of the present disclosure will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. The accompanying drawings are used to better understand the present solution and do not constitute a limitation of the present disclosure. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, among which:
[0027] Figure 1 A schematic diagram showing an exemplary operating environment in which embodiments of the present disclosure can be implemented;
[0028] Figure 2 A flowchart of a network resource request scheduling method provided by an embodiment of the present disclosure is shown;
[0029] Figure 3 A structural diagram of a network resource request scheduling device provided by an embodiment of the present disclosure is shown;
[0030] Figure 4 A structural diagram of an exemplary electronic device capable of implementing an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0031] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0032] In addition, the term "and / or" in this article is only a description of the association relationship between the associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0033] In response to the problems in the background technology, the embodiments of the present disclosure provide a method and device for scheduling network resource requests when network resource requests increase suddenly. Specifically, the CDN cache server can detect its own network bandwidth occupancy. If it detects that its own network bandwidth occupancy is higher than or equal to a preset network bandwidth occupancy threshold, it will redirect the received network resource request to a CDN cache server whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in the CDN node to which it belongs. In this way, in the extreme case of a sudden increase in network resource requests, it can ensure that the network bandwidth of the CDN cache server will not be fully utilized, thereby ensuring the CDN service quality.
[0034] The network resource request scheduling method, apparatus, device and storage medium provided by the embodiments of the present disclosure are described in detail below with reference to the accompanying drawings through specific embodiments.
[0035] Figure 1 A schematic diagram of an exemplary operating environment in which embodiments of the present disclosure can be implemented is shown, Figure 1 As shown, the operating environment 100 may include: a user terminal, a CDN cache server, and a CDN scheduling device.
[0036] The user terminal may be a mobile electronic device or a non-mobile electronic device. For example, the mobile electronic device may be a mobile phone, a tablet computer, a laptop computer, a PDA or an ultra-mobile personal computer (UMPC), etc., and the non-mobile electronic device may be a personal computer (PC), a supercomputer or a smart TV, etc.
[0037] A CDN cache server is a server in a CDN cache node, which is used to cache resources such as images, music, videos, files in websites (such as HTML files, CSS files, and JS files), and software installation packages. It can be seen that multiple CDN cache servers can be deployed in a CDN cache node.
[0038] The CDN scheduling device is a load balancing device in the CDN, such as a global load balancing device (Global Server Load Balance, GSLB).
[0039] As an example, a CDN cache server detects its own network bandwidth usage in real time. If it detects that its own network bandwidth usage is higher than or equal to a preset network bandwidth usage threshold, it determines a CDN cache server in its CDN node whose network bandwidth usage is lower than the preset network bandwidth usage threshold based on the network bandwidth usage of other CDN cache servers in its CDN node obtained from the CDN scheduling device, and redirects the network resource request sent by the user terminal to a CDN cache server in its CDN node whose network bandwidth usage is lower than the preset network bandwidth usage threshold. This ensures that the network bandwidth of the CDN cache server will not be fully utilized in the extreme case of a sudden increase in network resource requests, thereby ensuring the CDN service quality.
[0040] Figure 2 A flowchart of a method for scheduling network resource requests when network resource requests increase suddenly is shown in an embodiment of the present disclosure. Figure 2 As shown, the network resource request scheduling method 200 may include the following steps:
[0041] S210: The user terminal sends a network resource request to the CDN cache server.
[0042] Among them, network resource requests are used to request resources such as pictures, music, videos, files in websites (html, css, js), software installation packages, etc., and are not restricted here.
[0043] It should be noted that before sending a network resource request, the CDN scheduling device needs to select the CDN cache server according to the load balancing strategy.
[0044] S220, the CDN cache server receives the network resource request and detects the network bandwidth usage in real time to improve the detection accuracy.
[0045] The network bandwidth usage may refer to the ratio of the used network bandwidth to the total network bandwidth or the upper limit network bandwidth, or may refer to the amount of network bandwidth used.
[0046] S230: If it is detected that the network bandwidth usage is higher than or equal to a preset network bandwidth usage threshold, the CDN cache server sends a network bandwidth usage request to the CDN scheduling device.
[0047] Exemplarily, the preset network bandwidth occupancy threshold may be 95%, 90%, 85%, etc. of the total network bandwidth or the upper limit network bandwidth. The network bandwidth occupancy request may be sent in real time or at a fixed time, which is not limited here.
[0048] S240, the CDN scheduling device receives the network bandwidth usage request, and in response to the network bandwidth usage request, sends the network bandwidth usage reported by other CDN cache servers in the CDN node to which the CDN cache server belongs to the CDN cache server.
[0049] In some embodiments, each CDN cache server in a CDN node may report its own network bandwidth usage to a CDN scheduling device in real time by calling an HTTP interface.
[0050] S250, the CDN cache server receives the network bandwidth usage of other CDN cache servers, and determines, based on the received network bandwidth usage of other CDN cache servers, a CDN cache server whose network bandwidth usage is lower than a preset network bandwidth usage threshold in its CDN node.
[0051] As an example, each CDN cache server in the CDN node may respectively set a corresponding preset network bandwidth occupation threshold to fully utilize the bandwidth of each CDN cache server.
[0052] For example, a preset network bandwidth occupancy threshold corresponding to each CDN cache server in a CDN node may be configured in a CDN scheduling device, and then the CDN cache server may obtain the preset network bandwidth occupancy threshold corresponding to each CDN cache server in its CDN node from the CDN scheduling device in advance.
[0053] S260, the CDN cache server redirects the received network resource request to a CDN cache server whose network bandwidth occupancy is lower than a preset network bandwidth occupancy threshold among its CDN nodes.
[0054] In some embodiments, the CDN cache server may select a CDN cache server that meets a preset condition from CDN cache servers in its CDN nodes whose network bandwidth occupancy is lower than a preset network bandwidth occupancy threshold.
[0055] The preset condition may be that the network bandwidth usage is the smallest; or the difference between the network bandwidth usage and a preset network bandwidth usage threshold is the largest, which is not limited here.
[0056] Then, a redirection instruction is sent to the user terminal, so that the user terminal can quickly send a network resource request to the selected CDN cache server according to the redirection instruction.
[0057] Specifically, a redirection instruction may be sent to the user terminal according to the IP address of the selected CDN cache server, so that the user terminal sends a network resource request to the selected CDN cache server according to the IP address in the redirection instruction.
[0058] A redirection instruction may also be sent to the user terminal through the CDN scheduling device according to the IP address of the selected CDN cache server, so that the user terminal sends a network resource request to the selected CDN cache server according to the IP address in the redirection instruction.
[0059] Optionally, the redirect instruction may be an HTTP 302 instruction, which is not limited here.
[0060] According to the embodiments of the present disclosure, the CDN cache server can detect its own network bandwidth occupancy. If it detects that its own network bandwidth occupancy is higher than or equal to a preset network bandwidth occupancy threshold, it will redirect the received network resource request to a CDN cache server whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in the corresponding CDN node. In this way, in the extreme case of a sudden increase in network resource requests, it can ensure that the network bandwidth of the CDN cache server will not be fully utilized, thereby ensuring the CDN service quality.
[0061] In some embodiments, in order to further avoid the service quality being affected by the CDN cache server being fully utilized due to the network bandwidth, after redirecting the received network resource request to other CDN cache servers, the CDN cache server may also send a redirection record of the network resource request to the CDN scheduling device, notifying the CDN scheduling device to stop allocating network resource requests to the CDN cache server until the network bandwidth occupancy uploaded by the CDN cache server is lower than a preset network bandwidth occupancy threshold.
[0062] It should be noted that if the network bandwidth usage of the CDN cache server is lower than the preset network bandwidth usage threshold, the CDN scheduling device will reallocate network resource requests to the CDN cache server, and the CDN cache server will process the network resource requests normally without redirection.
[0063] In other embodiments, if the network bandwidth usage of other CDN cache servers in the CDN node is higher than or equal to the preset network bandwidth usage threshold, the CDN cache server can redirect the received network resource request to the CDN cache server in the corresponding backup node, further ensuring that the network bandwidth of the CDN cache server will not be fully utilized.
[0064] The network resource request scheduling method provided by the present disclosure may be described in detail below in conjunction with a specific embodiment, as follows:
[0065] Assume that there are five CDN cache servers in a CDN node, namely server 1, server 2, server 3, server 4, and server 5. Each server detects its own network bandwidth usage in real time and obtains the network bandwidth usage reported by other servers from the CDN scheduling device at regular intervals.
[0066] If server 1 detects that its current network bandwidth usage is 96%, which is higher than its corresponding preset network bandwidth usage threshold (95%), it is determined that the network bandwidth usage of server 1 is too high and is no longer available, and a server needs to be selected to process the network resource request on its behalf.
[0067] Assume that the network bandwidth usage of server 2 obtained by server 1 from the CDN scheduling device is 80%, the network bandwidth usage of server 3 is 75%, the network bandwidth usage of server 4 is 65%, and the network bandwidth usage of server 5 is 97%. The preset network bandwidth usage threshold corresponding to server 2 is 90%, the preset network bandwidth usage threshold corresponding to server 3 is 95%, the preset network bandwidth usage threshold corresponding to server 4 is 80%, and the preset network bandwidth usage threshold corresponding to server 5 is 95%.
[0068] At this time, server 1 can determine that server 2, server 3, and server 4 are respectively lower than their corresponding preset network bandwidth occupancy thresholds, and respectively calculate the difference between the network bandwidth occupancy of server 2, server 3, and server 4 and the preset network bandwidth occupancy threshold. The difference corresponding to server 2 is 10%, the difference corresponding to server 3 is 20%, and the difference corresponding to server 4 is 15%. Therefore, server 3 with the largest difference can be selected to process the network resource request received for itself.
[0069] Next, Server 1 redirects the received network resource request to Server 3, and sends a redirection record of the network resource request to the CDN scheduling device, notifying the CDN scheduling device to stop allocating network resource requests to Server 1 until the network bandwidth usage uploaded by the CDN cache server is lower than the preset network bandwidth usage threshold. In this way, in the extreme case of a sudden increase in network resource requests, the network bandwidth of the CDN cache server will not be fully utilized, thereby ensuring the CDN service quality.
[0070] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should be aware that the present disclosure is not limited by the order of the actions described, because according to the present disclosure, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily required by the present disclosure.
[0071] The above is an introduction to the method embodiment. The following is a further explanation of the scheme disclosed in the present invention through an apparatus embodiment.
[0072] Figure 3 FIG. 4 shows a structural diagram of a network resource request scheduling device when network resource requests increase suddenly according to an embodiment of the present disclosure, such as Figure 3 As shown, the network resource request scheduling device 300 can be applied to a CDN cache server, including:
[0073] The detection module 310 is used to detect the network bandwidth usage.
[0074] The redirection module 320 is used to redirect the received network resource request to a CDN cache server whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in the CDN node to which it belongs if it is detected that the network bandwidth occupancy is higher than or equal to the preset network bandwidth occupancy threshold.
[0075] In some embodiments, the detection module 310 is specifically used to:
[0076] Detect network bandwidth usage in real time.
[0077] In some embodiments, the network bandwidth usage of other CDN cache servers in the CDN node is obtained from the CDN scheduling device.
[0078] In some embodiments, each CDN cache server in the CDN node to which the CDN cache server belongs is respectively set with a corresponding preset network bandwidth occupation threshold.
[0079] In some embodiments, the redirection module 320 is specifically used to:
[0080] If it is detected that the network bandwidth usage is higher than or equal to the preset network bandwidth usage threshold, a CDN cache server that meets the preset conditions is selected from the CDN cache servers in the CDN nodes whose network bandwidth usage is lower than the preset network bandwidth usage threshold.
[0081] A redirection instruction is sent to the user terminal that sends the network resource request, so that the user terminal sends the network resource request to the selected CDN cache server according to the redirection instruction.
[0082] In some embodiments, the network resource request scheduling device 300 further includes:
[0083] The sending module is used to send a redirection record of the network resource request to the CDN scheduling device, and notify the CDN scheduling device to stop allocating network resource requests to the CDN cache server until the network bandwidth usage uploaded by the CDN cache server is lower than a preset network bandwidth usage threshold.
[0084] In some embodiments, the redirection module 320 is further used to redirect the received network resource request to the CDN cache server in the corresponding backup node if the network bandwidth usage of other CDN cache servers in the corresponding CDN node is higher than or equal to a preset network bandwidth usage threshold.
[0085] Understandably, Figure 3 Each module / unit in the network resource request scheduling device 300 shown has the function of implementing each step in the network resource request scheduling method 200 provided in the embodiment of the present disclosure, and can achieve its corresponding technical effect. For the sake of brevity, it will not be repeated here.
[0086] Figure 4 A block diagram of an electronic device that can be used to implement an embodiment of the present disclosure is shown. The electronic device 400 is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device 400 can also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present disclosure described and / or required herein.
[0087] like Figure 4 As shown, the electronic device 400 may include a computing unit 401, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 402 or a computer program loaded from a storage unit 408 into a random access memory (RAM) 403. In the RAM 403, various programs and data required for the operation of the electronic device 400 can also be stored. The computing unit 401, the ROM 402, and the RAM 403 are connected to each other via a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.
[0088] Multiple components in the electronic device 400 are connected to the I / O interface 405, including: an input unit 406, such as a keyboard, a mouse, etc.; an output unit 407, such as various types of displays, speakers, etc.; a storage unit 408, such as a disk, an optical disk, etc.; and a communication unit 409, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 409 allows the electronic device 400 to exchange information / data with other devices through a computer network such as the Internet and / or various telecommunication networks.
[0089] The computing unit 401 may be a variety of general and / or special processing components with processing and computing capabilities. Some examples of the computing unit 401 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, digital signal processors (DSPs), and any appropriate processors, controllers, microcontrollers, etc. The computing unit 401 performs the various methods and processes described above, such as method 200. For example, in some embodiments, the method 200 may be implemented as a computer program product, including a computer program, which is tangibly contained in a computer-readable medium, such as a storage unit 408. In some embodiments, part or all of the computer program may be loaded and / or installed on the device 400 via ROM 402 and / or communication unit 409. When the computer program is loaded into RAM 403 and executed by the computing unit 401, one or more steps of the method 200 described above may be performed. Alternatively, in other embodiments, the computing unit 401 may be configured to perform the method 200 in any other appropriate manner (e.g., by means of firmware).
[0090] The various embodiments described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include: being implemented in one or more computer programs, which can be executed and / or interpreted on a programmable system including at least one programmable processor, which can be a dedicated or general programmable processor, which can receive data and instructions from a storage system, at least one input device, and at least one output device, and transmit data and instructions to the storage system, the at least one input device, and the at least one output device.
[0091] The program code for implementing the method of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general-purpose computer, a special-purpose computer, or other programmable data processing device, so that the program code, when executed by the processor or controller, enables the functions / operations specified in the flow chart and / or block diagram to be implemented. The program code may be executed entirely on the machine, partially on the machine, partially on the machine and partially on a remote machine as a stand-alone software package, or entirely on a remote machine or server.
[0092] In the context of the present disclosure, a computer-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A computer-readable medium may be a computer-readable signal medium or a computer-readable storage medium. A computer-readable medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or equipment, or any suitable combination of the foregoing. A more specific example of a computer-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0093] It should be noted that the present disclosure also provides a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to execute method 200 and achieve the corresponding technical effect achieved by executing the method in the embodiment of the present disclosure. For the sake of concise description, they are not repeated here.
[0094] In addition, the present disclosure also provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the method 200 is implemented.
[0095] To provide interaction with a user, the above-described embodiments may be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or trackball) through which the user can provide input to the computer. Other types of devices may also be used to provide interaction with the user; for example, the feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form (including acoustic input, voice input, or tactile input).
[0096] The embodiments described above can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer with a graphical user interface or a web browser through which a user can interact with implementations of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), and the Internet.
[0097] A computer system may include a client and a server. The client and the server are generally remote from each other and usually interact through a communication network. The relationship of client and server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, a server of a distributed system, or a server combined with a blockchain.
[0098] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps recorded in this disclosure can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solutions disclosed in this disclosure can be achieved, and this document does not limit this.
[0099] The above specific implementations do not constitute a limitation on the protection scope of the present disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions can be made according to design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present disclosure shall be included in the protection scope of the present disclosure.
Claims
1. A method for scheduling network resource requests when network resource requests increase suddenly, characterized in that: The method is applied to a CDN cache server, comprising: Detect network bandwidth usage; If it is detected that the network bandwidth usage is higher than or equal to the preset network bandwidth usage threshold, redirecting the received network resource request to a CDN cache server in the CDN node to which the network bandwidth usage is lower than the preset network bandwidth usage threshold; The network bandwidth usage refers to the proportion of the used network bandwidth to the total network bandwidth or the upper limit network bandwidth; the preset network bandwidth usage threshold is lower than 100%; The method further comprises: Sending a redirection record of the network resource request to a CDN scheduling device, notifying the CDN scheduling device to stop allocating network resource requests to the CDN cache server until the network bandwidth occupancy of the CDN cache server uploads is lower than a preset network bandwidth occupancy threshold; If it is detected that the network bandwidth usage is higher than or equal to a preset network bandwidth usage threshold, redirecting the received network resource request to a CDN cache server in the CDN node to which the network bandwidth usage is lower than the preset network bandwidth usage threshold includes: If it is detected that the network bandwidth occupancy is higher than or equal to a preset network bandwidth occupancy threshold, a CDN cache server that meets the preset conditions is selected from the CDN cache servers whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in the CDN node; A redirection instruction is sent to the user terminal that sends the network resource request, so that the user terminal sends the network resource request to the selected CDN cache server according to the redirection instruction.
2. The method according to claim 1, characterized in that The detecting of network bandwidth usage includes: Detect network bandwidth usage in real time.
3. The method according to claim 1, characterized in that The network bandwidth usage of other CDN cache servers in the CDN node is obtained from the CDN scheduling device.
4. The method according to claim 1, characterized in that: Each CDN cache server in the CDN node to which the CDN cache server belongs is respectively set with a corresponding preset network bandwidth occupancy threshold.
5. The method according to claim 1, characterized in that The method further comprises: If the network bandwidth usage of other CDN cache servers in the CDN node is higher than or equal to the preset network bandwidth usage threshold, the received network resource request is redirected to the CDN cache server in the corresponding backup node.
6. A network resource request scheduling device when network resource requests increase suddenly, characterized in that: The device is applied to a CDN cache server, including: A detection module, used to detect network bandwidth usage; A redirection module, configured to redirect the received network resource request to a CDN cache server in the CDN node to which the network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold if it is detected that the network bandwidth occupancy is higher than or equal to the preset network bandwidth occupancy threshold; The network bandwidth usage refers to the proportion of the used network bandwidth to the total network bandwidth or the upper limit network bandwidth; the preset network bandwidth usage threshold is lower than 100%; The device also includes: A sending module, configured to send a redirection record of the network resource request to a CDN scheduling device, and notify the CDN scheduling device to stop allocating network resource requests to the CDN cache server until the network bandwidth occupancy of the CDN cache server is lower than a preset network bandwidth occupancy threshold; The redirection module is specifically used for: If it is detected that the network bandwidth occupancy is higher than or equal to a preset network bandwidth occupancy threshold, a CDN cache server that meets the preset conditions is selected from the CDN cache servers whose network bandwidth occupancy is lower than the preset network bandwidth occupancy threshold in the CDN node; A redirection instruction is sent to the user terminal that sends the network resource request, so that the user terminal sends the network resource request to the selected CDN cache server according to the redirection instruction.
7. An electronic device, characterized in that: The electronic device comprises: at least one processor; and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 5.
8. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to enable a computer to execute the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Resource access method, cache server, storage medium and electronic equipment
CN111510491A
