CN109981795B - Resource request scheduling method and device - Google Patents

Resource request scheduling method and device Download PDF

Info

Publication number
CN109981795B
CN109981795B CN201910280273.9A CN201910280273A CN109981795B CN 109981795 B CN109981795 B CN 109981795B CN 201910280273 A CN201910280273 A CN 201910280273A CN 109981795 B CN109981795 B CN 109981795B
Authority
CN
China
Prior art keywords
data center
internet data
terminal
scheduling
resource request
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.)
Active
Application number
CN201910280273.9A
Other languages
Chinese (zh)
Other versions
CN109981795A (en
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.)
Beijing QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and 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 Beijing QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN201910280273.9A priority Critical patent/CN109981795B/en
Publication of CN109981795A publication Critical patent/CN109981795A/en
Application granted granted Critical
Publication of CN109981795B publication Critical patent/CN109981795B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • H04L67/63Routing a service request depending on the request content or context

Abstract

The application discloses a method and a device for scheduling resource requests, wherein the method comprises the following steps: receiving a resource request sent by a terminal, wherein the resource request carries an internet protocol address (IP) of the terminal; determining a scheduling group matched with the IP of the terminal in response to the resource request; acquiring at least one IP prefix identification associated with each Internet data center in the scheduling group, wherein the IP prefix identification associated with the Internet data center belongs to a front designated position of an IP corresponding to a historical access terminal with communication connection failure in the Internet data center; determining a target internet data center meeting preset conditions from the scheduling group, wherein the preset conditions comprise: the associated at least one IP prefix mark does not comprise the front assigned position of the IP of the terminal; and dispatching the resource request of the terminal to the server of the target internet data center. The scheme of the application can more reasonably realize the scheduling of the resource request and reduce the blocking situation at the user terminal side.

Description

Resource request scheduling method and device
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method and an apparatus for scheduling resource requests.
Background
In a multimedia service system based on a Content Delivery Network (CDN), a scheduling server needs to schedule a resource request of a user terminal to a cache server of an appropriate Internet Data Center (IDC) so as to return a multimedia resource requested by the resource request to the user terminal through the cache server.
After the scheduling server schedules the resource request to a cache server of a certain internet data center, if the communication connection between the user terminal and the cache server cannot be established, the scheduling server needs to re-schedule the resource request of the user terminal to cache servers of other internet data centers. Therefore, in the existing scheduling mode, the situation that the user terminal cannot request the multimedia resource in time due to the unreasonable resource request scheduling is easily caused, so that the situation that the user terminal side is stuck is more.
Disclosure of Invention
In view of this, the present application provides a method and an apparatus for scheduling a resource request, so as to implement scheduling of the resource request more reasonably and reduce the occurrence of jamming at the user terminal side.
In order to achieve the above object, in one aspect, the present application provides a resource request scheduling method, including:
receiving a resource request sent by a terminal, wherein the resource request is used for requesting multimedia resources and carries an internet protocol address (IP) of the terminal;
in response to the resource request, determining a scheduling group matched with the IP of the terminal, wherein the scheduling group comprises at least one Internet data center;
acquiring at least one IP prefix identification associated with each Internet data center in the scheduling group, wherein the IP prefix identification associated with the Internet data center belongs to a front designated position of an IP corresponding to a historical access terminal with communication connection failure in the Internet data center;
determining a target internet data center meeting preset conditions from the scheduling group, wherein the preset conditions comprise: the associated at least one IP prefix identification does not comprise a pre-designated location of the IP of the terminal;
and dispatching the resource request of the terminal to a server of the target internet data center.
Preferably, the determining the scheduling group matched with the IP of the terminal includes:
determining the area where the terminal is located and a network operator to which the terminal belongs according to the IP of the terminal;
and determining a scheduling group matched with the region where the terminal is located and the network operator to which the terminal belongs.
Preferably, the at least one IP prefix identifier associated with each internet data center is obtained by:
acquiring a risk terminal set corresponding to the internet data center, wherein the risk terminal set comprises: a plurality of historical access terminals which are scheduled to the Internet data center before the current time and are not successfully communicated with the Internet data center;
clustering the IPs of the plurality of historical access terminals to obtain a plurality of IP clustering groups, wherein each IP clustering group comprises the IP of at least one historical access terminal, and the front designated positions of the IPs belonging to the same clustering group are the same;
sequencing the plurality of IP cluster groups according to the sequence of the number of the included IPs from large to small, and selecting a set number of IP cluster groups which are sequenced in the front;
and taking the front designated positions of the IP corresponding to the IP cluster groups with the set number as the IP prefix identifications associated with the Internet data center.
Preferably, the determining, from the scheduling group, a target internet data center that meets a preset condition includes:
selecting a candidate internet data center from the dispatch group;
detecting whether a front designated bit of the IP of the terminal belongs to at least one IP prefix identification associated with the candidate Internet data center;
if the front designated bit of the IP of the terminal belongs to at least one IP prefix mark of the candidate Internet data center, returning to execute the operation of selecting one candidate Internet data center from the scheduling group so as to reselect one candidate Internet data center;
and if the pre-designated position of the IP of the terminal does not belong to at least one IP prefix identification of the candidate Internet data center, determining the candidate Internet data center as a target Internet data center.
Preferably, the method further comprises the following steps:
determining an external internet data center associated with the scheduling group under the condition that no target internet data center meeting preset conditions exists in the scheduling group;
and dispatching the resource request to a server of the external Internet data center.
Preferably, after the scheduling the resource request of the terminal to the server of the target internet data center, the method further includes:
determining the number of times of scheduling failure corresponding to the resource request of the terminal under the condition that the scheduling failure exists between the resource request of the terminal and the target internet data center;
when the number of times of scheduling failure corresponding to the resource request of the terminal does not reach a set number of times, determining an internet data center which is not used as the target internet data center and meets the preset condition from the scheduling group, using the determined internet data center as a current target internet data center, and scheduling the resource request of the terminal to a server of the current target internet data center;
and when the scheduling failure times corresponding to the resource request of the terminal reach the set times, determining the external Internet data center associated with the scheduling group, and scheduling the resource request to a server of the external Internet data center.
In another aspect, the present application further provides a resource request scheduling apparatus, including:
a request receiving unit, configured to receive a resource request sent by a terminal, where the resource request is used to request a multimedia resource and carries an internet protocol address IP of the terminal;
a scheduling group matching unit, configured to determine, in response to the resource request, a scheduling group that matches the IP of the terminal, where the scheduling group includes at least one internet data center;
the failure identification determining unit is used for acquiring at least one IP prefix identification associated with each Internet data center in the scheduling group, wherein the IP prefix identification associated with the Internet data center belongs to the pre-designated position of the IP corresponding to the historical access terminal with communication connection failure in the Internet data center;
a target center determining unit, configured to determine, from the scheduling group, a target internet data center that meets a preset condition, where the preset condition includes: the associated at least one IP prefix identification does not comprise a pre-designated location of the IP of the terminal;
and the request scheduling unit is used for scheduling the resource request of the terminal to a server of the target internet data center.
Preferably, the method further comprises the following steps:
a prefix identification determining unit, configured to obtain at least one IP prefix identification associated with the internet data center by:
acquiring a risk terminal set corresponding to the internet data center, wherein the risk terminal set comprises: a plurality of historical access terminals which are scheduled to the Internet data center before the current time and are not successfully communicated with the Internet data center;
clustering the IPs of the plurality of historical access terminals to obtain a plurality of IP clustering groups, wherein each IP clustering group comprises the IP of at least one historical access terminal, and the front designated positions of the IPs belonging to the same clustering group are the same;
sequencing the plurality of IP cluster groups according to the sequence of the number of the included IPs from large to small, and selecting a set number of IP cluster groups which are sequenced in the front;
and taking the front designated positions of the IP corresponding to the IP cluster groups with the set number as the IP prefix identifications associated with the Internet data center.
Preferably, the target center determining unit includes:
the candidate selecting subunit is used for selecting a candidate internet data center from the scheduling group;
the IP detection subunit is used for detecting whether the front designated bit of the IP of the terminal belongs to at least one IP prefix mark associated with the candidate Internet data center;
a reselection triggering subunit, configured to, if a front designated bit of the IP of the terminal belongs to at least one IP prefix identifier of the candidate internet data center, return to perform the operation of selecting one candidate internet data center from the scheduling group to reselect one candidate internet data center;
and the target determining subunit is used for determining the candidate internet data center as the target internet data center if the pre-designated position of the IP of the terminal does not belong to at least one IP prefix identifier of the candidate internet data center.
Preferably, the method further comprises the following steps:
the external group determining unit is used for determining the external internet data center associated with the scheduling group under the condition that the target internet data center meeting the preset condition does not exist in the scheduling group;
and the rescheduling unit is used for scheduling the resource request to a server of the external Internet data center.
As can be seen, in the embodiment of the present application, after receiving a resource request of a terminal and determining a scheduling group matching an IP of the terminal, at least one IP prefix identifier associated with each internet data center in the scheduling group is obtained. Because the IP prefix identifier associated with the internet data center is used to represent the pre-designated location of the IP corresponding to the terminal having a communication connection failure with the internet data center, if at least one prefix identifier associated with the internet data center includes the pre-designated location of the IP of the terminal, it indicates that the risk of a communication connection failure occurs when the resource request of the terminal is scheduled to the internet data center. Based on this, the method and the device determine that at least one associated prefix identifier does not include the target internet data center of the pre-designated location of the IP corresponding to the terminal from the scheduling group, and schedule the resource request of the terminal to the target internet data center can greatly reduce the situation of scheduling failure caused by communication connection failure, thereby improving the rationality of resource request scheduling, and being beneficial to reducing the situation of terminal jamming caused by unreasonable resource scheduling.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on the provided drawings without creative efforts.
Fig. 1 is a schematic structural diagram of a multimedia resource service system to which a resource request scheduling method of the present application is applied;
FIG. 2 is a flowchart illustrating an embodiment of a resource request scheduling method according to the present application;
FIG. 3 is a flow diagram illustrating one implementation of the present application for determining at least one IP prefix tag associated with an Internet data center;
FIG. 4 is a flowchart illustrating a resource request scheduling method according to another embodiment of the present application;
fig. 5 is a schematic diagram illustrating a component of a resource request scheduling apparatus according to the present application.
Detailed Description
The resource request scheduling method and device in the multimedia resource service system schedule the resource request so as to realize more reasonable scheduling of the resource request.
The multimedia resource service system may be a service system for implementing multimedia resources such as audio and video based on a Content Delivery Network (CDN).
For ease of understanding, the multimedia resource service system to which the present application is applicable will be described below.
Fig. 1 shows a schematic diagram of a component architecture of a multimedia resource service system according to the present application.
As can be seen from fig. 1, the multimedia resource service system may include: at least one scheduling server (also referred to as a scheduler) 100 and a plurality of Internet Data Centers (IDCs) 110 connected to the scheduling server.
Wherein each IDC includes at least one server 111. Typically, one IDC will have multiple servers.
The IDC may be a computer room, or may be other network architectures capable of hosting at least one server.
The server 111 may also be referred to as a cache server, and is used for storing multimedia resources such as audio and video that can be provided to the terminal in the multimedia resource service system.
In practical application, in order to better provide multimedia resource services for terminals in different regions and different operators, the multimedia resource service system is divided into a plurality of scheduling groups based on configuration information such as regions where servers of the multimedia resource service system are located and configured resources, wherein each scheduling group can also be regarded as a scheduling area, and each scheduling group includes at least one IDC. As can be seen in fig. 1, at least one IDC within the same dashed box belongs to the same scheduling group.
In practical applications, the terminal 200 may send a resource request to the scheduling server.
And the scheduling server may determine, in response to the resource request, an IDC suitable for providing the resource service for the terminal from the plurality of IDCs, and schedule the resource request to a server in the determined IDC to provide the resource service, such as audio or video, for the terminal through the server in the IDC.
With the above commonalities, the resource request scheduling method of the present application is introduced below.
For example, referring to fig. 2, which shows a flowchart of an embodiment of a resource request scheduling method according to the present application, the method of this embodiment may be applied to the aforementioned scheduling server, and this embodiment may include:
s201, receiving a resource request sent by a terminal.
The resource request is used for requesting multimedia resources, and the resource request carries an internet protocol address (IP) of the terminal.
For example, when the multimedia resource service system is a service platform for providing video services, the resource request may request to acquire or access a video resource.
And S202, responding to the resource request, and determining a scheduling group matched with the IP of the terminal.
Wherein the scheduling group includes at least one IDC.
It will be appreciated that the appropriate scheduling group needs to be determined before scheduling a resource request to a particular server within the IDC. There may be various specific ways to determine the scheduling group matching the IP of the terminal.
For example, as an alternative, the area where the terminal is located and the network operator to which the terminal belongs may be determined according to the IP of the terminal; then, a scheduling group matching the region where the terminal is located and the network operator to which the terminal belongs is determined. The corresponding relation between different regions and network operators and the scheduling group can be configured in advance, and the scheduling group matched with the region where the terminal is located and the network operator to which the terminal belongs can be obtained by inquiring the corresponding relation.
For example, the relationship between the region where the terminal is located and the operator and the scheduling group may be:
shanghai and carrier 1: the third dispatch group in the Shanghai region.
Shanghai and carrier 2: the first dispatch group in the Shanghai region.
It can be understood that, in practical applications, the scheduling server may configure the scheduling group selection policy as needed, and the above is only one implementation manner based on the network operator and the region where the terminal is located, and other manners for determining the scheduling group are also applicable to this embodiment.
S203, acquiring at least one IP prefix mark associated with each Internet data center in the scheduling group.
The IP prefix mark associated with the Internet data center belongs to the front designated position of the IP corresponding to the historical access terminal with communication connection failure in the Internet data center.
In the embodiment of the application, in order to determine which terminals may have access failure when accessing the internet data center, at least one IP prefix identifier corresponding to each IDC is maintained in the scheduling server. Each IP prefix mark corresponds to a front designated position of one type of IP and is used for representing the same type of IP with the front designated position, and the front designated positions of the IPs represented by different IP prefix marks are different because the different IP prefix marks are used for representing different types of IPs.
For example, the first designated bits may be the first 24 bits, in which case each IP prefix identification is the first 24 bits of a certain IP.
It can be understood that at least one IP prefix identifier corresponding to each IDC is used to characterize a class of IP corresponding to a terminal having a communication connection failure with the IDC, and therefore, for each IDC, in order to be able to determine at least one IP prefix identifier associated with the IDC, multiple IP prefix identifiers may be extracted based on the history of accessing the IPs of multiple terminals having a failure with the IDC corresponding to the IDC. Wherein, the terminals which have failed to access the IDC historically can be terminals which are scheduled to the IDC by the scheduling server before the current time, but have not successfully established communication connection with the server in the IDC.
For example, for IDC1, the scheduling server has been scheduling resource requests of terminal a, terminal B, terminal C, and terminal D to a server in IDC1, but terminal a, terminal B, and terminal D cannot successfully establish a communication connection with the server in IDC1, resulting in scheduling failure. In this case, the respective IP addresses of the terminal a, the terminal B, and the terminal D may be obtained, and the first 24 bits of the IPs of the three terminals are respectively extracted (taking the first 24 bits as an example), and if the first 24 bits of the IP addresses of the three terminals are all different, three IP prefix identifications corresponding to the first 24 bits of the three IPs are obtained, and the three prefix identifications are the IP prefix identifications associated with the IDC 1.
Optionally, a risk list may be maintained in the scheduling server for each internet data center, where the risk list includes at least one IP prefix identifier.
And S204, determining a target Internet data center meeting preset conditions from the scheduling group.
Wherein, the preset conditions include: the associated at least one IP prefix identifies a pre-designated bit that does not include the IP of the terminal. For example, if none of the pre-designated bits of the IP of the terminal belongs to at least one IP prefix identifier associated with a certain internet data center in the scheduling group, the internet data center may be determined as the internet data center satisfying the preset condition.
For the convenience of distinguishing, the internet data center meeting the preset conditions is called as a target internet data center. It can be understood that, because the scheduling group only needs to determine one internet data center to process the resource request each time, the scheduling group only needs to determine one internet data center meeting the preset condition.
It is to be understood that, when a target internet data center is determined from the dispatch group, the pre-designated location of the IP of the terminal may be sequentially compared with at least one IP prefix identifier associated with each internet data center in the dispatch group until a target internet data center is determined. The comparison sequence may also be determined according to the resource allocation condition of each internet data center in the scheduling group, and then the target internet data center is determined through sequential comparison, which is not limited in the present application.
It can be understood that, since the IP prefix identifier associated with the internet data center is used to characterize the pre-designated location of the IP corresponding to the terminal having the communication connection failure with the internet data center, if at least one prefix identifier associated with the internet data center includes the pre-designated location of the IP of the terminal, it indicates that there is a high risk of the communication connection failure when the resource request of the terminal is scheduled to the internet data center. On the contrary, if at least one prefix mark associated with the internet data center does not include the pre-designated bit of the IP of the terminal, it indicates that after the resource request of the terminal is scheduled to the internet data center, the risk of communication connection failure between the terminal and the internet center is low, thereby facilitating the successful scheduling of the resource request.
And S205, dispatching the resource request of the terminal to the server of the target Internet data center.
After the target internet data center is determined, the resource request of the terminal can be dispatched to any server of the target internet data center. Alternatively, a server suitable for processing the resource request is determined from the target internet data center, and then the resource request is dispatched to the server determined in the target internet data center. The server determined from the target internet data center to be suitable for processing the resource request may be selected according to the resource allocation of each server in the target internet data center, the remaining available resources, and the like.
It can be understood that the scheduling of the resource request of the terminal to the server of the target internet data center is equivalent to the server of the target internet data center processing the resource request of the terminal; it can also be considered that the server of the target internet data center is allocated to the terminal, so that the terminal accesses the server of the target internet data center to request the resource service corresponding to the resource request.
It can be understood that, in practical applications, there may be no internet data center meeting the preset condition in the scheduling group, and in this case, it indicates that all the IDCs in the scheduling group belong to the IDCs with the risk of communication connection failure with the terminal. In order to improve the reliability of the dispatch, in the present application, each dispatch group is also associated with an external internet data center, also referred to as the retry internet data center of the dispatch group. For example, the external IDC may be an IDC that does not belong to the scheduling area to which the scheduling group belongs and is closer to the geographical area range or the configuration where the scheduling group is located.
Correspondingly, if it is determined in step S204 that there is no target internet data center satisfying the preset condition in the scheduling group, it may be determined that an external internet data center associated with the scheduling group is present, and the resource request of the terminal is scheduled to a server of the external internet data center.
As can be seen, in the embodiment of the present application, after receiving a resource request of a terminal and determining a scheduling group matching an IP of the terminal, at least one IP prefix identifier associated with each internet data center in the scheduling group is obtained. Because the IP prefix identifier associated with the internet data center is used to represent the pre-designated location of the IP corresponding to the terminal having a communication connection failure with the internet data center, if at least one prefix identifier associated with the internet data center includes the pre-designated location of the IP of the terminal, it indicates that the risk of a communication connection failure occurs when the resource request of the terminal is scheduled to the internet data center. Based on this, the method and the device determine that at least one associated prefix identifier does not include the target internet data center of the pre-designated location of the IP corresponding to the terminal from the scheduling group, and schedule the resource request of the terminal to the target internet data center can greatly reduce the situation of scheduling failure caused by communication connection failure, thereby improving the rationality of resource request scheduling, and being beneficial to reducing the situation of terminal jamming caused by unreasonable resource scheduling.
To facilitate understanding of at least one IP prefix identifier associated with each internet data center in the present application, an implementation manner of determining at least one IP prefix identifier associated with an internet data center is described as an example below.
For example, referring to fig. 3, which shows a schematic flow chart of an implementation of determining at least one IP prefix identifier associated with an internet data center in an embodiment of the present application, the embodiment may include the following flows:
s301, acquiring a risk terminal set corresponding to the Internet data center.
Wherein the set of risky terminals comprises: and a plurality of historical access terminals which are scheduled to the Internet data center before the current time and are not successfully connected with the Internet data center in a communication mode.
For example, the risk terminal set may be determined by obtaining the scheduling logs of the plurality of terminals in the specified time period before the current time, and according to the scheduling logs of the terminals.
Wherein, the dispatch log may record: the scheduling method comprises the steps of scheduling an IP of a server, and a client request, wherein the client request can carry information used for representing IDCs to which the scheduling request of the client is scheduled and the number of times of scheduling failure. Therefore, which IDCs the terminal scheduled by the scheduling server corresponds to respectively can be determined based on the scheduling log, and the IP of the terminal with the communication connection failure exists in the plurality of terminals corresponding to each IDC, that is, the IP of the client with the service failure of each IDC can be analyzed. For example, by segmenting the request field of the client, a request with retry not equal to 0 is extracted, and the IP and IDC corresponding to the terminal of the request are obtained.
Of course, the scheduling log may also record information such as IDC of the returned video, IP of the returned video, time of the scheduling server processing the request, and the like, which is not limited herein.
S302, clustering the IP of the plurality of historical access terminals to obtain a plurality of IP clustering groups.
And each IP cluster group comprises the IP of at least one historical access terminal, and the front assigned positions of the IPs belonging to the same cluster group are the same.
If the former designated bit is the first 24 bits, the IPs of the plurality of history access terminals may be clustered based on the first 24 bits of the IPs of the plurality of history access terminals, so that the IPs with the same first 24 bits may be clustered into a cluster group, and thus, the first 24 bits of all IPs in the cluster group are the same.
S303, sequencing the plurality of IP cluster groups according to the sequence of the number of the included IPs from large to small, and selecting a set number of IP cluster groups with the top sequencing.
It can be understood that if more IP data are contained in a cluster group, the first 24 bits of the corresponding IP of the cluster group belong to an IP with a higher risk of communication connection failure with the IDC. Therefore, the present application selects a predetermined number of IP cluster groups including a large number of IPs.
S304, the front designated positions of the IP corresponding to the IP cluster groups with the set number are all used as the IP prefix identification associated with the Internet data center.
If the first designated bit (the first 16 bits are the example) of all the IPs in a selected IP cluster group is "01100100.00000100", then "01100100.00000100" can be identified as an IP prefix associated with IDC. Correspondingly, an IP prefix identifier can be obtained for each selected IP cluster group, so that a risk list including at least one IP prefix identifier can be obtained.
Of course, the step S303 is only an optional step, and in practical application, the first 24 bits of the IP corresponding to each IP cluster group may also be used as the IP prefix identifier associated with the IDC.
It can be understood that there are various specific implementation manners for determining the target internet data center satisfying the preset condition, and the resource request scheduling method of the present application is described below by taking one implementation manner as an example.
For example, referring to fig. 4, which shows a flowchart of an embodiment of a resource request scheduling method according to the present application, the method of the embodiment may include:
s401, receiving a resource request sent by a terminal.
The resource request is used for requesting multimedia resources, and the resource request carries an internet protocol address (IP) of the terminal.
S402, responding to the resource request, and determining the area where the terminal is located and the network operator to which the terminal belongs according to the IP of the terminal.
S403, determine a scheduling group matching with the region where the terminal is located and the network operator to which the terminal belongs.
Wherein the scheduling group includes at least one IDC.
It should be noted that steps S402 and S403 are one implementation manner of determining a scheduling group for a terminal, and other manners are also applicable to this embodiment.
S404, acquiring at least one IP prefix mark associated with each Internet data center in the scheduling group.
The IP prefix mark associated with the Internet data center belongs to the front designated position of the IP corresponding to the historical access terminal with communication connection failure in the Internet data center.
S405, selecting a candidate Internet data center from the scheduling group.
For example, the scheduling server may select an internet data center with a higher bandwidth condition as a candidate internet data center according to bandwidth conditions (e.g., total bandwidth and bandwidth occupation ratio) of each internet data center in scheduling.
It is understood that, when the step S405 is performed for the first time, the candidate internet data center may be selected based on the bandwidth condition only. When the step S405 is executed repeatedly, one internet data center needs to be selected as a candidate internet data center from among the internet data centers that have not been selected.
S406, detecting whether the front designated bit of the IP of the terminal belongs to at least one IP prefix mark associated with the candidate Internet data center, if so, executing a step S407; if not, step S408 is performed.
If the front designated bit of the IP of the terminal belongs to the prefix identification of at least one IP of the candidate Internet data center, the fact that the currently selected candidate Internet data center is allocated to the terminal is high in risk of communication connection failure is shown. In this case, it is necessary to return to step S405 to re-select a candidate internet data center from the internet data centers that are not selected as the candidate internet data centers.
S407, detecting whether an Internet data center which is not used as a candidate Internet data center exists in the scheduling group, if so, returning to the step S405 to reselect a candidate Internet data center; if not, step S409 is performed.
If all the internet data centers in the scheduling group are already used as candidate internet data centers and compared with the pre-designated bits of the IP of the terminal, but the pre-designated bits do not meet the preset condition, it indicates that there is no target candidate internet data center meeting the preset condition in the scheduling group, and in this case, step S409 needs to be executed.
Of course, this step S407 is an optional step, and the purpose thereof is to improve the reliability of scheduling.
S408, if the pre-designated position of the IP of the terminal does not belong to at least one IP prefix identification of the candidate Internet data center, determining the candidate Internet data center as a target Internet data center, and scheduling the resource request of the terminal to the target Internet data center.
S409, under the condition that no target Internet data center meeting preset conditions exists in the scheduling group, determining an external Internet data center associated with the scheduling group, and scheduling the resource request to a server of the external Internet data center.
It is understood that, in any of the above embodiments of the present application, after the resource request of the terminal is scheduled to the server of the target internet data center, if the terminal and the server of the target internet data center can successfully establish a communication connection, the scheduling is successful, in which case, the server of the target internet data center may process the resource request of the terminal and provide the corresponding multimedia resource for the terminal.
However, if the terminal cannot establish a communication connection with the server of the target internet data center, the terminal is failed to schedule the resource request. In this case, the scheduling server may consider the target internet data center to be unsuitable for the terminal, and may no longer select another server from the target internet data center to serve the terminal. Accordingly, the scheduling server needs to reschedule the resource request of the terminal so as to schedule the terminal to a server in another internet data center.
Optionally, when the scheduling server determines that there is a scheduling failure between the resource request of the terminal and the target internet data center, the scheduling server determines the number of times of scheduling failure corresponding to the resource request of the terminal. For example, in the case that the terminal has a communication connection failure with the server of the target internet data center, the terminal may resend a retried resource request to the scheduling server, and the retried resource request may carry a number of times of representing the resource request resent by the terminal and an identifier of the IDC where the scheduling failure exists.
For example, an unscheduled resource request sent from the terminal to the scheduling server may include a field "retry-0", where retry-0 indicates that the resource request is unscheduled and is not a retry request. Correspondingly, if the resource request of the terminal fails in scheduling, the resource request retransmitted by the terminal may carry a field "retry-1 & e-6 & z-wuhan 4_ gwbn", where "retry-1" indicates that the resource request is a retry request with one scheduling failure, and the IDC with the last scheduling failure is "wuhan 4_ gwbn".
Considering that if the scheduling server selects IDCs from the scheduling group suitable for the IP of the terminal for multiple times, scheduling failure occurs, it may indicate that the IDCs in the scheduling group are not suitable for the terminal, and in this case, it may be necessary to select IDCs from outside the scheduling group. Therefore, when the number of times of scheduling failures corresponding to the resource request of the terminal does not reach the set number of times, determining the internet data center which is not used as the target internet data center and meets the preset condition from the scheduling group, using the determined internet data center as the current target internet data center, and scheduling the resource request of the terminal to the server of the current target internet data center.
Correspondingly, when the number of times of scheduling failure corresponding to the resource request of the terminal reaches the set number of times, determining the external internet data center associated with the scheduling group, and scheduling the resource request to the server of the external internet data center.
For example, assuming that the currently determined scheduling group suitable for the terminal is scheduling group S1, IDC1, IDC2, IDC3, and IDC4 are included in the scheduling group S1, and the scheduling group has associated retry IDC of IDC8, and it is assumed that the set number is 3.
Then, if the scheduling server schedules the scheduling request of the terminal to IDC1 and IDC2 in turn, but both scheduling requests fail to be scheduled. In this case, the scheduling request sent by the terminal to the scheduling server may carry "retry ═ 2" and "Z ═ IDC1, IDC 2", and the scheduling server may determine that the number of scheduling failures is two (less than the preset number: 3) according to "retry ═ 2", and then the scheduling server may select one IDC that satisfies the preset condition from the IDC3 and the IDC4, and allocate the scheduling request of the terminal to the selected IDC.
If the scheduling server schedules scheduling requests of the terminal to IDC1, IDC2, and IDC3 in sequence, and the scheduling requests all fail to be scheduled three times. In this case, the scheduling request sent by the terminal to the scheduling server may carry "retry is 3" and "Z is IDC1, IDC2, IDC 3", and the scheduling server may determine that the number of scheduling failures reaches a preset number (i.e., 3) according to "retry is 3", and then the scheduling server may allocate the scheduling request to the retry IDC associated with the scheduling group and allocate the retry IDC to IDC 8.
On the other hand, the application also provides a resource request scheduling device. For example, referring to fig. 5, a schematic diagram of a resource request scheduling apparatus according to the present application is shown, and the apparatus is applied to a scheduling server, and includes:
a request receiving unit 501, configured to receive a resource request sent by a terminal, where the resource request is used to request a multimedia resource and carries an internet protocol address IP of the terminal;
a scheduling group matching unit 502, configured to determine, in response to the resource request, a scheduling group that matches the IP of the terminal, where the scheduling group includes at least one internet data center;
a failure identifier determining unit 503, configured to obtain at least one IP prefix identifier associated with each internet data center in the scheduling group, where the IP prefix identifier associated with an internet data center belongs to a pre-designated location of an IP corresponding to a historical access terminal where there is a communication connection failure in the internet data center;
a target center determining unit 504, configured to determine, from the scheduling group, a target internet data center that meets preset conditions, where the preset conditions include: the associated at least one IP prefix identification does not comprise a pre-designated location of the IP of the terminal;
a request scheduling unit 505, configured to schedule the resource request of the terminal to a server of the target internet data center.
Optionally, the scheduling group matching unit includes:
an attribute determining subunit, configured to determine, according to the IP of the terminal, a region where the terminal is located and a network operator to which the terminal belongs;
and the group matching subunit is used for determining a scheduling group matched with the region where the terminal is located and the network operator to which the terminal belongs.
Optionally, the apparatus may further include:
a prefix identification determining unit, configured to obtain at least one IP prefix identification associated with the internet data center by:
acquiring a risk terminal set corresponding to the internet data center, wherein the risk terminal set comprises: a plurality of historical access terminals which are scheduled to the Internet data center before the current time and are not successfully communicated with the Internet data center;
clustering the IPs of the plurality of historical access terminals to obtain a plurality of IP clustering groups, wherein each IP clustering group comprises the IP of at least one historical access terminal, and the front designated positions of the IPs belonging to the same clustering group are the same;
sequencing the plurality of IP cluster groups according to the sequence of the number of the included IPs from large to small, and selecting a set number of IP cluster groups which are sequenced in the front;
and taking the front designated positions of the IP corresponding to the IP cluster groups with the set number as the IP prefix identifications associated with the Internet data center.
In one possible implementation, the target center determining unit includes:
the candidate selecting subunit is used for selecting a candidate internet data center from the scheduling group;
the IP detection subunit is used for detecting whether the front designated bit of the IP of the terminal belongs to at least one IP prefix mark associated with the candidate Internet data center;
a reselection triggering subunit, configured to, if a front designated bit of the IP of the terminal belongs to at least one IP prefix identifier of the candidate internet data center, return to perform the operation of selecting one candidate internet data center from the scheduling group to reselect one candidate internet data center;
and the target determining subunit is used for determining the candidate internet data center as the target internet data center if the pre-designated position of the IP of the terminal does not belong to at least one IP prefix identifier of the candidate internet data center.
Optionally, the apparatus of the present application may further include:
the external group determining unit is used for determining the external internet data center associated with the scheduling group under the condition that the target internet data center meeting the preset condition does not exist in the scheduling group;
and the external rescheduling unit is used for scheduling the resource request to a server of the external Internet data center.
Optionally, the apparatus may further include:
a failure frequency determining unit, configured to determine, after the request scheduling unit schedules the resource request of the terminal to the server of the target internet data center, a scheduling failure frequency corresponding to the resource request of the terminal when it is determined that there is a scheduling failure between the resource request of the terminal and the target internet data center;
a rescheduling unit, configured to determine, when the number of times of scheduling failures corresponding to the resource request of the terminal does not reach a set number of times, an internet data center that is not a target internet data center and satisfies the preset condition from the scheduling group, use the determined internet data center as a current target internet data center, and schedule the resource request of the terminal to a server of the current target internet data center;
and the external scheduling unit is used for determining the external Internet data center associated with the scheduling group when the scheduling failure times corresponding to the resource request of the terminal reach the set times, and scheduling the resource request to a server of the external Internet data center.
It should be noted that, in the present specification, the embodiments are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. For the device-like embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that it is obvious to those skilled in the art that various modifications and improvements can be made without departing from the principle of the present invention, and these modifications and improvements should also be considered as the protection scope of the present invention.

Claims (10)

1. A method for scheduling resource requests, comprising:
receiving a resource request sent by a terminal, wherein the resource request is used for requesting multimedia resources and carries an internet protocol address (IP) of the terminal;
in response to the resource request, determining a scheduling group matched with the IP of the terminal, wherein the scheduling group comprises at least one Internet data center;
acquiring at least one IP prefix identification associated with each Internet data center in the scheduling group, wherein the IP prefix identification associated with the Internet data center belongs to a front designated position of an IP corresponding to a historical access terminal with communication connection failure in the Internet data center;
determining a target internet data center meeting preset conditions from the scheduling group, wherein the preset conditions comprise: the associated at least one IP prefix identification does not comprise a pre-designated location of the IP of the terminal;
and dispatching the resource request of the terminal to a server of the target internet data center.
2. The method according to claim 1, wherein the determining the scheduling group matching the IP of the terminal comprises:
determining the area where the terminal is located and a network operator to which the terminal belongs according to the IP of the terminal;
and determining a scheduling group matched with the region where the terminal is located and the network operator to which the terminal belongs.
3. The method according to claim 1, wherein the at least one IP prefix identifier associated with each internet data center is obtained by:
acquiring a risk terminal set corresponding to the internet data center, wherein the risk terminal set comprises: a plurality of historical access terminals which are scheduled to the Internet data center before the current time and are not successfully communicated with the Internet data center;
clustering the IPs of the plurality of historical access terminals to obtain a plurality of IP clustering groups, wherein each IP clustering group comprises the IP of at least one historical access terminal, and the front designated positions of the IPs belonging to the same clustering group are the same;
sequencing the plurality of IP cluster groups according to the sequence of the number of the included IPs from large to small, and selecting a set number of IP cluster groups which are sequenced in the front;
and taking the front designated positions of the IP corresponding to the IP cluster groups with the set number as the IP prefix identifications associated with the Internet data center.
4. The method according to claim 1, wherein the determining a target internet data center satisfying a preset condition from the scheduling group comprises:
selecting a candidate internet data center from the dispatch group;
detecting whether a front designated bit of the IP of the terminal belongs to at least one IP prefix identification associated with the candidate Internet data center;
if the front designated bit of the IP of the terminal belongs to at least one IP prefix mark of the candidate Internet data center, returning to execute the operation of selecting one candidate Internet data center from the scheduling group so as to reselect one candidate Internet data center;
and if the pre-designated position of the IP of the terminal does not belong to at least one IP prefix identification of the candidate Internet data center, determining the candidate Internet data center as a target Internet data center.
5. The method for scheduling resource requests according to claim 1 or 4, further comprising:
determining an external internet data center associated with the scheduling group under the condition that no target internet data center meeting preset conditions exists in the scheduling group;
and dispatching the resource request to a server of the external Internet data center.
6. The method according to claim 1 or 4, further comprising, after the scheduling the resource request of the terminal to the server of the target internet data center:
determining the number of times of scheduling failure corresponding to the resource request of the terminal under the condition that the scheduling failure exists between the resource request of the terminal and the target internet data center;
when the number of times of scheduling failure corresponding to the resource request of the terminal does not reach a set number of times, determining an internet data center which is not used as the target internet data center and meets the preset condition from the scheduling group, using the determined internet data center as a current target internet data center, and scheduling the resource request of the terminal to a server of the current target internet data center;
and when the scheduling failure times corresponding to the resource request of the terminal reach the set times, determining the external Internet data center associated with the scheduling group, and scheduling the resource request to a server of the external Internet data center.
7. A resource request scheduling apparatus, comprising:
a request receiving unit, configured to receive a resource request sent by a terminal, where the resource request is used to request a multimedia resource and carries an internet protocol address IP of the terminal;
a scheduling group matching unit, configured to determine, in response to the resource request, a scheduling group that matches the IP of the terminal, where the scheduling group includes at least one internet data center;
the failure identification determining unit is used for acquiring at least one IP prefix identification associated with each Internet data center in the scheduling group, wherein the IP prefix identification associated with the Internet data center belongs to the pre-designated position of the IP corresponding to the historical access terminal with communication connection failure in the Internet data center;
a target center determining unit, configured to determine, from the scheduling group, a target internet data center that meets a preset condition, where the preset condition includes: the associated at least one IP prefix identification does not comprise a pre-designated location of the IP of the terminal;
and the request scheduling unit is used for scheduling the resource request of the terminal to a server of the target internet data center.
8. The apparatus as claimed in claim 7, further comprising:
a prefix identification determining unit, configured to obtain at least one IP prefix identification associated with the internet data center by:
acquiring a risk terminal set corresponding to the internet data center, wherein the risk terminal set comprises: a plurality of historical access terminals which are scheduled to the Internet data center before the current time and are not successfully communicated with the Internet data center;
clustering the IPs of the plurality of historical access terminals to obtain a plurality of IP clustering groups, wherein each IP clustering group comprises the IP of at least one historical access terminal, and the front designated positions of the IPs belonging to the same clustering group are the same;
sequencing the plurality of IP cluster groups according to the sequence of the number of the included IPs from large to small, and selecting a set number of IP cluster groups which are sequenced in the front;
and taking the front designated positions of the IP corresponding to the IP cluster groups with the set number as the IP prefix identifications associated with the Internet data center.
9. The apparatus as claimed in claim 7, wherein the target center determining unit comprises:
the candidate selecting subunit is used for selecting a candidate internet data center from the scheduling group;
the IP detection subunit is used for detecting whether the front designated bit of the IP of the terminal belongs to at least one IP prefix mark associated with the candidate Internet data center;
a reselection triggering subunit, configured to, if a front designated bit of the IP of the terminal belongs to at least one IP prefix identifier of the candidate internet data center, return to perform the operation of selecting one candidate internet data center from the scheduling group to reselect one candidate internet data center;
and the target determining subunit is used for determining the candidate internet data center as the target internet data center if the pre-designated position of the IP of the terminal does not belong to at least one IP prefix identifier of the candidate internet data center.
10. The apparatus as claimed in claim 7 or 9, further comprising:
the external group determining unit is used for determining the external internet data center associated with the scheduling group under the condition that the target internet data center meeting the preset condition does not exist in the scheduling group;
and the rescheduling unit is used for scheduling the resource request to a server of the external Internet data center.
CN201910280273.9A 2019-04-09 2019-04-09 Resource request scheduling method and device Active CN109981795B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910280273.9A CN109981795B (en) 2019-04-09 2019-04-09 Resource request scheduling method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910280273.9A CN109981795B (en) 2019-04-09 2019-04-09 Resource request scheduling method and device

Publications (2)

Publication Number Publication Date
CN109981795A CN109981795A (en) 2019-07-05
CN109981795B true CN109981795B (en) 2021-09-07

Family

ID=67083652

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910280273.9A Active CN109981795B (en) 2019-04-09 2019-04-09 Resource request scheduling method and device

Country Status (1)

Country Link
CN (1) CN109981795B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110535853B (en) * 2019-08-28 2021-06-22 北京奇艺世纪科技有限公司 Video request scheduling method, device, server and storage medium
CN111934958B (en) * 2020-07-29 2022-03-29 深圳市高德信通信股份有限公司 IDC resource scheduling service management platform

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102035660A (en) * 2009-09-24 2011-04-27 中国移动通信集团公司 Internet data center (IDC) network-based service processing method, equipment and system
CN104394441A (en) * 2014-11-27 2015-03-04 北京奇艺世纪科技有限公司 Video content distribution scheduling method, device and system
WO2018113514A1 (en) * 2016-12-19 2018-06-28 腾讯科技(深圳)有限公司 Cdn management system, method and apparatus
CN109428839A (en) * 2017-08-31 2019-03-05 华为技术有限公司 A kind of CDN dispatching method, equipment and system

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102035660A (en) * 2009-09-24 2011-04-27 中国移动通信集团公司 Internet data center (IDC) network-based service processing method, equipment and system
CN104394441A (en) * 2014-11-27 2015-03-04 北京奇艺世纪科技有限公司 Video content distribution scheduling method, device and system
WO2018113514A1 (en) * 2016-12-19 2018-06-28 腾讯科技(深圳)有限公司 Cdn management system, method and apparatus
CN109428839A (en) * 2017-08-31 2019-03-05 华为技术有限公司 A kind of CDN dispatching method, equipment and system

Also Published As

Publication number Publication date
CN109981795A (en) 2019-07-05

Similar Documents

Publication Publication Date Title
CN109040259B (en) CDN node distribution method and system based on MEC
CN110677405B (en) Data processing method and device, electronic equipment and storage medium
US11431827B2 (en) Data center management system
CN106686102B (en) Service node switching method and device
CN110336848B (en) Scheduling method, scheduling system and scheduling equipment for access request
CN107948004B (en) Video CDN (content delivery network) calling optimization method and device
CN109981795B (en) Resource request scheduling method and device
CN110366276A (en) Serviceization framework base station
CN110109766B (en) Data interaction method and device based on cross-department and cross-platform data sharing exchange
CN109819023B (en) Distributed transaction processing method and related product
CN111901881B (en) Transmission method and device
CN114338650A (en) File transmission method and device, electronic equipment and readable storage medium
CN112380072A (en) Multi-data center access method and system
CN110365605B (en) Message sending method, device, equipment and storage medium
EP3301626A1 (en) Method, device, and system
EP2439881B1 (en) Cluster system and request message distribution method for processing multi-node transaction
CN113612861B (en) Remote access method, system and computer readable storage medium
CN109672721B (en) Media file pushing method and device, server and computer readable storage medium
CN111147468A (en) User access method, device, electronic equipment and storage medium
CN111163186A (en) ID generation method, device, equipment and storage medium
CN107707939B (en) Video access method, access balance server, central server and system
CN110569178B (en) Interface early warning method and system based on big data platform
CN111930482A (en) Task processing method, device and equipment based on node cluster and storage medium
CN104639379A (en) Proxy testing method and device
CN114546641B (en) Comprehensive energy control system based on Internet of things gateway and node intelligent box

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
GR01 Patent grant
GR01 Patent grant