CN111770186A - Multi-content distribution network load balancing method and device - Google Patents

Multi-content distribution network load balancing method and device Download PDF

Info

Publication number
CN111770186A
CN111770186A CN202010632039.0A CN202010632039A CN111770186A CN 111770186 A CN111770186 A CN 111770186A CN 202010632039 A CN202010632039 A CN 202010632039A CN 111770186 A CN111770186 A CN 111770186A
Authority
CN
China
Prior art keywords
content distribution
distribution network
target
speed
average
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010632039.0A
Other languages
Chinese (zh)
Inventor
陈天宇
梁波
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhuhai Kingsoft Online Game Technology Co Ltd
Original Assignee
Zhuhai Kingsoft Online Game Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhuhai Kingsoft Online Game Technology Co Ltd filed Critical Zhuhai Kingsoft Online Game Technology Co Ltd
Priority to CN202010632039.0A priority Critical patent/CN111770186A/en
Publication of CN111770186A publication Critical patent/CN111770186A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/101Server selection for load balancing based on network conditions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application provides a multi-content distribution network load balancing method and a multi-content distribution network load balancing device, wherein the multi-content distribution network load balancing method comprises the following steps: acquiring the average downloading speed of at least two content distribution networks for providing downloading; determining a content distribution network corresponding to the average downloading speed meeting the preset conditions as a target content distribution network; monitoring a target download speed of a target content distribution network; and when the target downloading speed is reduced to be below a threshold value, selecting one content distribution network from other content distribution networks except the target content distribution network to switch to a new target content distribution network. The method realizes load balance among a plurality of content distribution networks and ensures that the content distribution network with the best selectivity can provide services.

Description

Multi-content distribution network load balancing method and device
Technical Field
The present application relates to the field of internet technologies, and in particular, to a method and an apparatus for balancing a load of a multi-content distribution network, a computing device, and a computer-readable storage medium.
Background
The Content Delivery Network (CDN) is an advanced traffic distribution Network constructed on the existing Network, and is an advanced Network in which a new Network architecture is added to the existing Network to distribute the Content of a website to the edge of the Network closest to a user, so as to improve the response speed of the user in accessing the website.
After a website content provider delivers website content to a website, the delivered content is cached in a CDN server for a user to download and browse, the website content provider usually selects services of multiple CDN manufacturers to ensure the quality of the CDN services, in a CDN system in the prior art, there is a problem of unbalanced download requirements of servers connected to multiple CDN services, which causes some CDN servers to operate in an overloaded state, while other CDN servers fail to fully exert their data download capabilities, the load balancing in the prior art is complicated, or a special architecture design is used, but this greatly increases the cost, or coordination processing is performed through software, but this increases network delay, and reduces the user experience.
Therefore, how to achieve a better load balancing effect at a lower cost becomes a problem to be solved urgently by technical staff at present.
Disclosure of Invention
In view of this, embodiments of the present application provide a method and an apparatus for load balancing of a multi-content distribution network, a computing device, and a computer-readable storage medium, so as to solve technical defects in the prior art.
According to a first aspect of the embodiments of the present application, there is provided a method for load balancing of a multi-content distribution network, including:
acquiring the average downloading speed of at least two content distribution networks for providing downloading;
determining a content distribution network corresponding to the average downloading speed meeting the preset conditions as a target content distribution network;
monitoring a target download speed of a target content distribution network;
and when the target downloading speed is reduced to be below a threshold value, selecting one content distribution network from other content distribution networks except the target content distribution network to switch to a new target content distribution network.
Optionally, before obtaining the average download speeds of at least two content distribution networks, the method further includes:
any one of the at least two content distribution networks is determined to be the target content distribution network.
Optionally, one content distribution network selected from the at least two content distribution networks is a target content distribution network, and the method includes:
and selecting one content distribution network from the at least two content distribution networks as a target content distribution network by adopting a consistent hash algorithm.
Optionally, obtaining an average download speed of downloads provided by at least two content distribution networks includes:
and respectively acquiring the average downloading speed of each content distribution network for providing downloading in the same preset time interval according to the preset time interval.
Optionally, determining the content distribution network corresponding to the average download speed meeting the preset condition as the target content distribution network includes:
and determining the content distribution network with the highest average downloading speed as a target content distribution network.
Optionally, selecting one of the content distribution networks to switch to a new target content distribution network in the other content distribution networks except the target content distribution network, includes:
and switching the content distribution network with the highest average downloading speed to a new target content distribution network in other content distribution networks except the target content distribution network.
Optionally, determining the content distribution network corresponding to the average download speed meeting the preset condition as the target content distribution network includes:
determining the fastest average downloading speed as a first downloading speed, and determining a second downloading speed according to the first speed;
taking the content distribution network with the average download speed larger than the second download speed as a candidate set of the content distribution network;
and randomly selecting one content distribution network from the content distribution network candidate set as a target content distribution network.
Optionally, selecting one of the content distribution networks to switch to a new target content distribution network in the other content distribution networks except the target content distribution network, includes:
and randomly switching a content distribution network except the target content distribution network into a new target content distribution network in the content distribution network candidate set.
According to a second aspect of the embodiments of the present application, there is provided a multi-content distribution network load balancing apparatus, including:
the acquisition module is configured to acquire the average downloading speed of the downloads provided by the at least two content distribution networks;
the first determining module is configured to determine a content distribution network corresponding to the average downloading speed meeting the preset conditions as a target content distribution network;
a monitoring module configured to monitor a target download speed of a target content distribution network;
and the switching module is configured to select one content distribution network to be switched to a new target content distribution network from other content distribution networks except the target content distribution network when the target downloading speed is reduced to be lower than a threshold value.
Optionally, the apparatus further comprises:
a second determination module configured to determine, as the target content distribution network, any one of the at least two content distribution networks.
Optionally, the second determining module is further configured to select one content distribution network from the at least two content distribution networks as the target content distribution network by using a consistent hashing algorithm.
Optionally, the obtaining module is further configured to obtain, according to a preset time interval, an average downloading speed at which each content distribution network provides downloading in the same preset time interval.
Optionally, the first determining module is further configured to determine the content distribution network with the fastest average downloading speed as the target content distribution network.
Optionally, the switching module is further configured to switch the content distribution network with the fastest average downloading speed to a new target content distribution network in other content distribution networks except the target content distribution network.
Optionally, the first determining module is further configured to determine that the fastest average downloading speed is the first downloading speed, and determine the second downloading speed according to the first speed; taking the content distribution network with the average download speed larger than the second download speed as a candidate set of the content distribution network; and randomly selecting one content distribution network from the content distribution network candidate set as a target content distribution network.
Optionally, the switching module is further configured to randomly select a content distribution network other than the target content distribution network from the content distribution network candidate set as a new target content distribution network.
According to a third aspect of embodiments herein, there is provided a computing device comprising a memory, a processor and computer instructions stored on the memory and executable on the processor, the processor implementing the steps of the multiple content distribution network load balancing method when executing the instructions.
According to a fourth aspect of embodiments of the present application, there is provided a computer-readable storage medium storing computer instructions which, when executed by a processor, implement the steps of the multi-content distribution network load balancing method.
In the embodiment of the application, the average downloading speed of the downloading is provided by acquiring at least two content distribution networks; the network connection condition of each content distribution network can be determined, and the content distribution network corresponding to the average downloading speed meeting the preset conditions is determined as the target content distribution network; the content distribution network with the best network connection speed is used as a target content distribution network, so that the use experience of a user is improved, and the target downloading speed of the target content distribution network is monitored; and under the condition that the target downloading speed is reduced to be below a threshold value, selecting one content distribution network from other content distribution networks except the target content distribution network to be switched to a new target content distribution network, and when the network fluctuates or the pressure of the target content distribution network is overlarge, ensuring that load balance is realized in a plurality of content distribution networks by switching the content distribution network, and ensuring that the target content distribution network can provide the best network downloading service.
Drawings
FIG. 1 is a block diagram of a computing device provided by an embodiment of the present application;
fig. 2 is a flowchart of a load balancing method for a multi-content distribution network according to an embodiment of the present application;
fig. 3 is a schematic diagram of a load balancing method for a multi-content distribution network according to another embodiment of the present application;
fig. 4 is a schematic structural diagram of a load balancing apparatus for a multi-content distribution network according to an embodiment of the present application.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present application. This application is capable of implementation in many different ways than those herein set forth and of similar import by those skilled in the art without departing from the spirit of this application and is therefore not limited to the specific implementations disclosed below.
The terminology used in the one or more embodiments of the present application is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of the present application. As used in one or more embodiments of the present application and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present application refers to and encompasses any and all possible combinations of one or more of the associated listed items.
It will be understood that, although the terms first, second, etc. may be used herein in one or more embodiments of the present application to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first aspect may be termed a second aspect, and, similarly, a second aspect may be termed a first aspect, without departing from the scope of one or more embodiments of the present application. The word "if" as used herein may be interpreted as "at … …" or "when … …" or "in response to a determination", depending on the context.
First, the noun terms to which one or more embodiments of the present invention relate are explained.
Content Delivery Network (CDN): the CDN is an intelligent virtual Network constructed on the basis of the existing Network, and enables a user to obtain required Content nearby by means of functional modules of load balancing, Content distribution, scheduling and the like of a central platform by means of edge servers deployed in various places, so that Network congestion is reduced, and the access response speed and hit rate of the user are improved. The key technology of the CDN is mainly content storage and distribution technology.
In the present application, a multi-content distribution network load balancing method and apparatus, a computing device and a computer readable storage medium are provided, which are described in detail in the following embodiments one by one.
FIG. 1 shows a block diagram of a computing device 100 according to an embodiment of the present application. The components of the computing device 100 include, but are not limited to, memory 110 and processor 120. The processor 120 is coupled to the memory 110 via a bus 130 and a database 150 is used to store data.
Computing device 100 also includes access device 140, access device 140 enabling computing device 100 to communicate via one or more networks 160. Examples of such networks include the Public Switched Telephone Network (PSTN), a Local Area Network (LAN), a Wide Area Network (WAN), a Personal Area Network (PAN), or a combination of communication networks such as the internet. Access device 140 may include one or more of any type of network interface (e.g., a Network Interface Card (NIC)) whether wired or wireless, such as an IEEE802.11 Wireless Local Area Network (WLAN) wireless interface, a worldwide interoperability for microwave access (Wi-MAX) interface, an ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a bluetooth interface, a Near Field Communication (NFC) interface, and so forth.
In one embodiment of the present application, the above-mentioned components of the computing device 100 and other components not shown in fig. 1 may also be connected to each other, for example, by a bus. It should be understood that the block diagram of the computing device architecture shown in FIG. 1 is for purposes of example only and is not limiting as to the scope of the present application. Those skilled in the art may add or replace other components as desired.
Computing device 100 may be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet, personal digital assistant, laptop, notebook, netbook, etc.), a mobile phone (e.g., smartphone), a wearable computing device (e.g., smartwatch, smartglasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. Computing device 100 may also be a mobile or stationary server.
Wherein, the processor 120 may execute the steps in the multi-content distribution network load balancing method shown in fig. 2. Fig. 2 shows a flowchart of a multi-content distribution network load balancing method according to an embodiment of the present application, including step 202 to step 208.
Step 202: an average download speed at which the at least two content distribution networks provide downloads is obtained.
The Content Delivery Network (CDN) is an intelligent virtual network constructed on the basis of the existing network, and enables users to obtain required content nearby by means of functional modules of load balancing, content delivery, scheduling and the like of a central platform by means of edge servers deployed in various places, so that network congestion is reduced, and the access response speed and hit rate of the users are improved.
After a website content provider delivers website content to a website, the delivered content is cached in a CDN server for a user to download and browse, and the website content provider usually selects services of multiple CDN manufacturers to ensure the quality of CDN services, and needs to implement load balancing among multiple CDNs used by the website content provider, thereby improving the utilization rate of the CDN.
Specifically, in practical applications, obtaining an average download speed of downloads provided by at least two content distribution networks includes: the method includes the steps that the average downloading speed of each content delivery network for providing downloading in the same preset time interval is obtained according to preset time intervals, namely, each CDN independently provides downloading service every other preset period of time, the average downloading speed of each CDN is recorded, the running state of each CDN can be known in real time, specifically, a CDN server of each CDN manufacturer independently provides downloading service, and the average downloading speed of each CDN server in the same time is recorded.
In the embodiment provided by the present application, the website content provider selects A, B CDN services of two CDN vendors, and lets A, B two servers corresponding to the two CDN vendors work independently to provide a download service for 2 minutes every 30 minutes, so that the average download speed of the server a is 5M/S and the average download speed of the server B is 4.7M/S.
Optionally, before obtaining the average download speeds of at least two content distribution networks, the method further includes: any one of the at least two content distribution networks is determined to be the target content distribution network.
Specifically, the website content provider may randomly select one CDN from the CDNs to provide service for the target CDN, and release the content of the website for the user to use, so that the operation cost of the website content provider is saved while the user experience is ensured.
In practical application, a consistent hashing algorithm can be adopted to select any one CDN from at least two CDNs as a target CDN, and the fairness of CDN selection can be improved by adopting the consistent hashing algorithm.
In the embodiment provided by the present application, following the above example, the content provider of the website selects a CDN server of a B vendor as the target CDN by using a consistent hashing algorithm.
Step 204: and determining the content distribution network corresponding to the average downloading speed meeting the preset conditions as a target content distribution network.
There are many methods for determining that the preset conditions are met, and the method can be used for standing at the angle of a user to provide better service for the user, and can also be used for standing at the angle of a website content provider to realize load balance among a plurality of CDNs used by the website content provider, so that the benefit of the website content provider is ensured.
For example, when the downloading speed of the user is considered as priority, the content distribution network with the highest average downloading speed is determined as the target content distribution network.
In a specific embodiment provided by the present application, obtaining the average download speed of each CDN server of 4 CDN operators is: the average downloading speed of the server A is 5M/S, the average downloading speed of the server B is 4.5M/S, the average downloading speed of the server C is 5.2M/S, the average downloading speed of the server D is 4.1M/S, and the target CDN is the C with the highest average downloading speed.
When the benefit of a website content provider is considered, when a certain CDN provided downloading speed in CDN manufacturers selected by the website content provider is good, the number of users on the CDN exceeds the upper limit of the users which can be accommodated, and other CDNs are idle, load balancing needs to be performed among a plurality of CDNs at the moment, specifically, the fastest average downloading speed is determined to be a first downloading speed, and a second downloading speed is determined according to the first speed; taking the content distribution network with the average download speed larger than the second download speed as a candidate set of the content distribution network; and randomly selecting one content distribution network from the content distribution network candidate set as a target content distribution network.
In another specific embodiment provided by the present application, the average download speed of each CDN server of 4 CDN operators is obtained as follows: the average download speed of the server A is 5M/S, the average download speed of the server B is 4.5M/S, the average download speed of the server C is 5.2M/S, the average download speed of the server D is 4.1M/S, the corresponding download speed of the server C is determined to be 5.2M/S of the first download speed, the difference value between the second download speed and the first download speed is preset to be 10 percent of the first download speed, i.e., the speed difference between the second download speed and the first download speed is within 10%, at this time, the second download speed is 4.68M/S, at this time, the average download speed of the a server and the C service is greater than 4.68M/S, then a and C are taken as CDN candidate set, and randomly selecting one CDN as a target CDN from the A and the C, and selecting the target CDN from the A and the C through a consistent hash algorithm in order to ensure fairness.
Step 206: a target download speed of the target content distribution network is monitored.
After the target CDN is determined, the target downloading speed of the target CDN for downloading is monitored in real time, and the target downloading speed is the real-time downloading speed of the target CDN.
Step 208: and when the target downloading speed is reduced to be below a threshold value, selecting one content distribution network from other content distribution networks except the target content distribution network to switch to a new target content distribution network.
When the target download speed of the target CDN fluctuates, such as the download speed drops sharply, or the download speed continues to be lower than the average download speed of the target CDN, it can be determined that the service provided by the target CDN has a problem, and in order to ensure the user experience and achieve load balancing between multiple CDNs for the website content provider, the CDNs need to be switched.
In the embodiment provided by the present application, following the above example, when the downloading speed of the user is considered preferentially, only the CDN with the highest average downloading speed needs to be selected from the remaining CDNs as the new target CDN, for example, the average downloading speed of the a server is 5M/S, the average downloading speed of the B server is 4.5M/S, the average downloading speed of the C server is 5.2M/S, the average downloading speed of the D server is 4.1M/S, when the downloading speed of the target CDN suddenly changes to 2M/S, it indicates that the network of the C server has a problem, and it needs to switch, and then the a with the highest average downloading speed is selected from A, B, D three servers as the new target CDN.
In another embodiment provided by the present application, following the above example, when considering the benefit of the website content provider, the average download speed of the a server is 5M/S, the average download speed of the B server is 4.5M/S, the average download speed of the C server is 5.2M/S, the average download speed of the D server is 4.1M/S, and a and C are used as a CDN candidate set.
Optionally, the method for balancing the load of the multi-content distribution network further includes: and respectively acquiring the average downloading speed of each content distribution network for providing downloading in the same preset time interval according to the preset time interval.
In practical application, in order to ensure load balancing among multiple CDNs, the average download speed of each CDN for providing download needs to be tested at intervals, and a target CDN is selected after each speed measurement, so as to achieve real-time CDN load balancing.
According to the load balancing method for the multi-content distribution network, the average downloading speed of downloading is provided by the at least two content distribution networks; the network connection condition of each content distribution network can be determined, and the content distribution network corresponding to the average downloading speed meeting the preset conditions is determined as the target content distribution network; the content distribution network with the best network connection speed is used as a target content distribution network, so that the use experience of a user is improved, and the target downloading speed of the target content distribution network is monitored; and under the condition that the target downloading speed is reduced to be below a threshold value, selecting one content distribution network from other content distribution networks except the target content distribution network to be switched to a new target content distribution network, and when the network fluctuates or the pressure of the target content distribution network is overlarge, ensuring that load balance is realized in a plurality of content distribution networks by switching the content distribution network, and ensuring that the target content distribution network can provide the best network downloading service.
Fig. 3 shows a multi-content delivery network load balancing method according to an embodiment of the present application, which is described by taking load balancing among 5 CDNs used by a certain website as an example, and includes steps 302 to 314.
Step 302: and randomly selecting a content distribution network to provide downloading service by adopting a consistent hash algorithm.
In the embodiment provided by the present application, a certain website uses the CDN services of A, B, C, D, E with 5 CDN operators in total,the IP address of each CDN service corresponding to the corresponding CDN server is respectively IPA,IPB,IPC,IPD,IPECalculating the IP address of the server corresponding to each CDN as a keyword to carry out Hash, and determining that the server providing the downloaded CDN is the IPB
Step 304: the average download speed of each content distribution network providing download is obtained.
In the embodiment provided by the present application, each server is enabled to provide a download service for 1 minute individually, and the average download speed of the download provided by each CDN server is recorded, which is respectively: server IPAHas an average download speed of 5.1M/S and a server IPBHas an average download speed of 4.9M/S and a server IPCHas an average download speed of 5.0M/S and a server IPDHas an average download speed of 4.3M/S and a server IPEThe average download speed of (2) is 4.5M/S.
Step 306: and determining the fastest average downloading speed as a first downloading speed, and determining a second downloading speed according to the first speed.
In the embodiment provided by the application, the fastest average downloading speed is determined as the IP of the serverAThe average download speed of the first download speed is 5.1M/S, the speed difference between the second download speed and the first download speed is within 10%, and the second download speed is 4.68M/S.
Step 308: and taking the content distribution network with the average downloading speed larger than the second downloading speed as a candidate set of the content distribution network.
In the embodiments provided in the present application, the server IP is determinedAServer IPBAnd server IPCIs greater than 4.68M/S. IP the serverAServer IPBAnd server IPCAs a CDN candidate set.
Step 310: and randomly selecting one content distribution network from the content distribution network candidate set as a target content distribution network.
In the embodiments provided in the present application, a consistent hashing algorithm is used to select a server IPCServing as a target CDN lifterFor downloading services.
It should be noted that if the server IPCWhen the number of user connections in the CDN candidate set exceeds a preset threshold, selecting another CDN as a target CDN from the CDN candidate set.
Step 312: a target download speed of the target content distribution network is monitored.
In the embodiment provided by the application, the real-time monitoring server IPCProviding real-time download speed of the download service.
Step 314: and in the case that the target downloading speed is reduced to be below a threshold value, randomly switching a content distribution network except the target content distribution network into a new target content distribution network in the content distribution network candidate set.
In the embodiments provided in the present application, when the server IPCWhen the real-time download speed lasts 30 seconds and is less than the second download speed of 4.68M/S, determining the IP of the serverCWhen a problem occurs in the network, a handover is required, i.e. server IP in the CDN candidate setAAnd server IPBOptionally one CDN acts as a new target CDN.
It should be noted that, the step 304 to the step 314 are executed again at regular intervals, such as 10 minutes or 30 minutes, and the above steps are executed at regular intervals, so that the capability of each CDN to provide downloading can be known in real time, the CDN server with the best performance can be switched at any time to provide better downloading service for the user, after the average downloading speed provided by each CDN server is obtained again, another CDN server can provide downloading service with a higher speed, the target CDN is switched, and if the difference between the average downloading speeds is smaller than a threshold, the current CDN is continuously used.
According to the load balancing method for the multi-content distribution network, the average downloading speed of downloading is provided by the at least two content distribution networks; the network connection condition of each content distribution network can be determined, and the content distribution network corresponding to the average downloading speed meeting the preset conditions is determined as the target content distribution network; the content distribution network with the best network connection speed is used as a target content distribution network, so that the use experience of a user is improved, and the target downloading speed of the target content distribution network is monitored; under the condition that the target downloading speed is reduced to be below a threshold value, one content distribution network is selected to be switched to a new target content distribution network in other content distribution networks except the target content distribution network, when the network fluctuates or the pressure of the target content distribution network is too high, the load balance in the plurality of content distribution networks is guaranteed through switching the content distribution network, the target content distribution network can be guaranteed to provide the best network downloading service, speed measurement between each CDN server is carried out at intervals, the downloading speed provided by each CDN server can be known in real time, the CDN servers with better performance are switched at any time, and the better downloading service is provided for users.
Corresponding to the above method embodiment, the present application further provides an embodiment of a multi-content distribution network load balancing apparatus, and fig. 4 shows a schematic structural diagram of the multi-content distribution network load balancing apparatus according to an embodiment of the present application. As shown in fig. 4, the apparatus includes:
an obtaining module 402 configured to obtain an average download speed of at least two content distribution networks providing downloads.
The first determining module 404 is configured to determine a content distribution network corresponding to the average downloading speed meeting the preset condition as a target content distribution network.
A monitoring module 406 configured to monitor a target download speed of the target content distribution network.
A switching module 408 configured to select one of the content distribution networks to switch to a new target content distribution network among the other content distribution networks except the target content distribution network when the target download speed falls below a threshold.
Optionally, the apparatus further comprises:
a second determination module configured to determine, as the target content distribution network, any one of the at least two content distribution networks.
Optionally, the second determining module is further configured to select one content distribution network from the at least two content distribution networks as the target content distribution network by using a consistent hashing algorithm.
Optionally, the obtaining module 402 is further configured to obtain, according to a preset time interval, an average downloading speed of each content distribution network providing downloading in the same preset time interval.
Optionally, the first determining module 404 is further configured to determine the content distribution network with the fastest average downloading speed as the target content distribution network.
Optionally, the switching module 408 is further configured to switch the content distribution network with the fastest average downloading speed to the new target content distribution network in other content distribution networks except the target content distribution network.
Optionally, the first determining module 404 is further configured to determine the fastest average downloading speed as a first downloading speed, and determine a second downloading speed according to the first speed; taking the content distribution network with the average download speed larger than the second download speed as a candidate set of the content distribution network; and randomly selecting one content distribution network from the content distribution network candidate set as a target content distribution network.
Optionally, the switching module 408 is further configured to randomly select a content distribution network other than the target content distribution network from the content distribution network candidate set as a new target content distribution network.
There is also provided in an embodiment of the present application a computing device, including a memory, a processor, and computer instructions stored on the memory and executable on the processor, where the processor executes the instructions to implement the steps of the method for load balancing for a multiple content distribution network.
An embodiment of the present application also provides a computer-readable storage medium storing computer instructions, which when executed by a processor, implement the steps of the method for load balancing of a multi-content distribution network as described above.
The above is an illustrative scheme of a computer-readable storage medium of the present embodiment. It should be noted that the technical solution of the storage medium and the technical solution of the multi-content distribution network load balancing method belong to the same concept, and details that are not described in detail in the technical solution of the storage medium can be referred to the description of the technical solution of the multi-content distribution network load balancing method.
The foregoing description of specific embodiments of the present application has been presented. Other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The computer instructions comprise computer program code which may be in the form of source code, object code, an executable file or some intermediate form, or the like. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-Only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, and the like. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that, for the sake of simplicity, the above-mentioned method embodiments are described as a series of acts or combinations, but those skilled in the art should understand that the present application is not limited by the described order of acts, as some steps may be performed in other orders or simultaneously according to the present application. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required in this application.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
The preferred embodiments of the present application disclosed above are intended only to aid in the explanation of the application. Alternative embodiments are not exhaustive and do not limit the invention to the precise embodiments described. Obviously, many modifications and variations are possible in light of the above teaching. The embodiments were chosen and described in order to best explain the principles of the application and its practical applications, to thereby enable others skilled in the art to best understand and utilize the application. The application is limited only by the claims and their full scope and equivalents.

Claims (11)

1. A multi-content distribution network load balancing method is characterized by comprising the following steps:
acquiring the average downloading speed of at least two content distribution networks for providing downloading;
determining a content distribution network corresponding to the average downloading speed meeting the preset conditions as a target content distribution network;
monitoring a target download speed of a target content distribution network;
and when the target downloading speed is reduced to be below a threshold value, selecting one content distribution network from other content distribution networks except the target content distribution network to switch to a new target content distribution network.
2. The multi-content distribution network load balancing method according to claim 1, wherein before obtaining the average download speed of at least two content distribution networks, the method further comprises:
any one of the at least two content distribution networks is determined to be the target content distribution network.
3. The method for load balancing of multiple content distribution networks according to claim 1, wherein selecting one of the at least two content distribution networks as the target content distribution network comprises:
and selecting one content distribution network from the at least two content distribution networks as a target content distribution network by adopting a consistent hash algorithm.
4. The method for load balancing among multiple content distribution networks according to claim 1, wherein obtaining an average download speed for at least two content distribution networks providing downloads comprises:
and respectively acquiring the average downloading speed of each content distribution network for providing downloading in the same preset time interval according to the preset time interval.
5. The method for load balancing of multiple content distribution networks according to claim 1, wherein determining the content distribution network corresponding to the average download speed meeting the preset condition as the target content distribution network comprises:
and determining the content distribution network with the highest average downloading speed as a target content distribution network.
6. The multi-content distribution network load balancing method according to claim 4, wherein selecting one of the content distribution networks to switch to a new target content distribution network among the other content distribution networks except the target content distribution network comprises:
and switching the content distribution network with the highest average downloading speed to a new target content distribution network in other content distribution networks except the target content distribution network.
7. The method for load balancing of multiple content distribution networks according to claim 1, wherein determining the content distribution network corresponding to the average download speed meeting the preset condition as the target content distribution network comprises:
determining the fastest average downloading speed as a first downloading speed, and determining a second downloading speed according to the first speed;
taking the content distribution network with the average download speed larger than the second download speed as a candidate set of the content distribution network;
and randomly selecting one content distribution network from the content distribution network candidate set as a target content distribution network.
8. The method for load balancing among multiple content distribution networks according to claim 7, wherein selecting one of the content distribution networks to switch to a new target content distribution network among the other content distribution networks except the target content distribution network comprises:
and randomly switching a content distribution network except the target content distribution network into a new target content distribution network in the content distribution network candidate set.
9. A multi-content distribution network load balancing apparatus, comprising:
the acquisition module is configured to acquire the average downloading speed of the downloads provided by the at least two content distribution networks;
the first determining module is configured to determine a content distribution network corresponding to the average downloading speed meeting the preset conditions as a target content distribution network;
a monitoring module configured to monitor a target download speed of a target content distribution network;
and the switching module is configured to select one content distribution network to be switched to a new target content distribution network from other content distribution networks except the target content distribution network when the target downloading speed is reduced to be lower than a threshold value.
10. A computing device comprising a memory, a processor, and computer instructions stored on the memory and executable on the processor, wherein the processor implements the steps of the method of any one of claims 1-8 when executing the instructions.
11. A computer-readable storage medium storing computer instructions, which when executed by a processor, perform the steps of the method of any one of claims 1 to 8.
CN202010632039.0A 2020-07-03 2020-07-03 Multi-content distribution network load balancing method and device Pending CN111770186A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010632039.0A CN111770186A (en) 2020-07-03 2020-07-03 Multi-content distribution network load balancing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010632039.0A CN111770186A (en) 2020-07-03 2020-07-03 Multi-content distribution network load balancing method and device

Publications (1)

Publication Number Publication Date
CN111770186A true CN111770186A (en) 2020-10-13

Family

ID=72724563

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010632039.0A Pending CN111770186A (en) 2020-07-03 2020-07-03 Multi-content distribution network load balancing method and device

Country Status (1)

Country Link
CN (1) CN111770186A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112583667A (en) * 2020-12-11 2021-03-30 上海哔哩哔哩科技有限公司 Content delivery network link evaluation method and device
CN113038190A (en) * 2021-02-23 2021-06-25 北京达佳互联信息技术有限公司 Scheduling method and scheduling device for content delivery network
CN114401449A (en) * 2021-12-27 2022-04-26 中国电信股份有限公司 Version upgrading method and device and readable storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105979566A (en) * 2016-07-27 2016-09-28 广东欧珀移动通信有限公司 Network connecting method and device and mobile terminal
WO2017107463A1 (en) * 2015-12-21 2017-06-29 乐视控股(北京)有限公司 Method and apparatus for delivering cdn addresses
CN107979638A (en) * 2017-11-16 2018-05-01 北京小米移动软件有限公司 Content providing, device, equipment and storage medium
CN108076117A (en) * 2016-11-14 2018-05-25 腾讯科技(深圳)有限公司 A kind of data download method and user terminal
CN108574883A (en) * 2018-02-11 2018-09-25 广东南方新媒体股份有限公司 The method for realizing multiple CDN Parallel downloads video segments
CN111193772A (en) * 2019-12-05 2020-05-22 商客通尚景科技(上海)股份有限公司 File downloading method and server

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017107463A1 (en) * 2015-12-21 2017-06-29 乐视控股(北京)有限公司 Method and apparatus for delivering cdn addresses
CN105979566A (en) * 2016-07-27 2016-09-28 广东欧珀移动通信有限公司 Network connecting method and device and mobile terminal
CN108076117A (en) * 2016-11-14 2018-05-25 腾讯科技(深圳)有限公司 A kind of data download method and user terminal
CN107979638A (en) * 2017-11-16 2018-05-01 北京小米移动软件有限公司 Content providing, device, equipment and storage medium
CN108574883A (en) * 2018-02-11 2018-09-25 广东南方新媒体股份有限公司 The method for realizing multiple CDN Parallel downloads video segments
CN111193772A (en) * 2019-12-05 2020-05-22 商客通尚景科技(上海)股份有限公司 File downloading method and server

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112583667A (en) * 2020-12-11 2021-03-30 上海哔哩哔哩科技有限公司 Content delivery network link evaluation method and device
CN113038190A (en) * 2021-02-23 2021-06-25 北京达佳互联信息技术有限公司 Scheduling method and scheduling device for content delivery network
CN114401449A (en) * 2021-12-27 2022-04-26 中国电信股份有限公司 Version upgrading method and device and readable storage medium

Similar Documents

Publication Publication Date Title
CN111770186A (en) Multi-content distribution network load balancing method and device
US9674279B2 (en) Methods, devices, and systems for allocating service nodes in a network
US9019945B2 (en) Service-assisted network access point selection
US9294363B2 (en) Adjusting quality of service in a cloud environment based on application usage
CN104703254B (en) network access method and device
CN110198332B (en) Scheduling method and device for content distribution network node and storage medium
EP3053326B1 (en) Method for a user to access at least one communication service provided via a data centre of a cloud computing system
WO2017071669A1 (en) Cache acceleration method and device
US11445422B2 (en) Adaptable network communications
CN106250536B (en) Method, device and system for setting space page background
CN110198267B (en) Traffic scheduling method, system and server
CN114222168A (en) Resource scheduling method and system
CN114064275A (en) Data processing method and device
CN111212087A (en) Method, device, equipment and storage medium for determining login server
CN110581784B (en) Node health check method, device and equipment
CN112243038B (en) Downloading method, terminal and computer storage medium
CN104836827B (en) Data processing method and system based on asymmetric P2P networks
CN114385596A (en) Data processing method and device
CN112637351B (en) File downloading method and device
CN111641732B (en) Intelligent scheduling method and device
CN114866790A (en) Live streaming scheduling method and device
Hu et al. Downloading trace study for BitTorrent P2P performance measurement and analysis
JP6595962B2 (en) Edge server, session sharing system, method and program
US11930544B2 (en) Selectively enabling identifier resources for connections in a fifth generation (5G) or other next generation wireless network
CA2865528C (en) Method, apparatus, and system for generating a p2p network scheme

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20201013