CN114760482A - Live broadcast source returning method and device - Google Patents

Live broadcast source returning method and device Download PDF

Info

Publication number
CN114760482A
CN114760482A CN202210324997.0A CN202210324997A CN114760482A CN 114760482 A CN114760482 A CN 114760482A CN 202210324997 A CN202210324997 A CN 202210324997A CN 114760482 A CN114760482 A CN 114760482A
Authority
CN
China
Prior art keywords
node
path
source
edge node
stream
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.)
Granted
Application number
CN202210324997.0A
Other languages
Chinese (zh)
Other versions
CN114760482B (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.)
Shanghai Bilibili Technology Co Ltd
Original Assignee
Shanghai Bilibili 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 Shanghai Bilibili Technology Co Ltd filed Critical Shanghai Bilibili Technology Co Ltd
Priority to CN202210324997.0A priority Critical patent/CN114760482B/en
Publication of CN114760482A publication Critical patent/CN114760482A/en
Application granted granted Critical
Publication of CN114760482B publication Critical patent/CN114760482B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/21Server components or server architectures
    • H04N21/218Source of audio or video content, e.g. local disk arrays
    • H04N21/2181Source of audio or video content, e.g. local disk arrays comprising remotely distributed storage units, e.g. when movies are replicated over a plurality of video servers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/21Server components or server architectures
    • H04N21/218Source of audio or video content, e.g. local disk arrays
    • H04N21/2187Live feed
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/21Server components or server architectures
    • H04N21/226Characteristics of the server or Internal components of the server
    • H04N21/2265Server identification by a unique number or address, e.g. serial number
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/232Content retrieval operation locally within server, e.g. reading video streams from disk arrays

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Databases & Information Systems (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application provides a live broadcast source returning method and a live broadcast source returning device, wherein the live broadcast source returning method comprises the following steps: receiving a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node; searching at least one distribution node of the live stream to be acquired according to the stream identifier; and determining a target source returning path of the edge node according to the type of at least one distribution node, and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to carry out source returning to obtain the to-be-obtained live stream. Therefore, the cost performance of the selected target source returning path is high, the source returning efficiency and the success rate are greatly improved, and the cost is reduced and the efficiency is improved.

Description

Live broadcast source returning method and device
Technical Field
The application relates to the technical field of live broadcast, in particular to a live broadcast source returning method. The application also relates to a live feed back device, a computing device and a computer readable storage medium.
Background
With the rapid development of computer and internet technologies, the live broadcast industry is rapidly developing, live broadcast audiences are continuously expanded, and various live broadcast layers are endless. In the live broadcast process, the live broadcast stream pushed by the anchor can be provided for users to watch through a Content Delivery Network (CDN), the traditional CDN carries out a large-scale distribution Network through a three-level tree structure of a source station, a secondary source station, and edge nodes, when live broadcast accesses, the CDN cannot distribute the live broadcast stream to each edge node in advance, when a user needs to access a certain live broadcast stream, the edge nodes can return to the source, that is, the edge nodes pull the required live broadcast stream to the source station or the secondary source station in real time.
In the prior art, source return paths of each edge node are fixed in advance, that is, through which path an edge node pulls a required live broadcast stream is fixed in advance, and the source return paths of the edge nodes are solidified, which may cause bandwidth waste or excessive bandwidth pressure, increase source return cost, and has low source return cost; moreover, if the source returning path fixed in advance is abnormal, the source returning may be repeatedly tried many times, which may cause source returning failure, and greatly affects the source returning efficiency and the source returning success rate.
Disclosure of Invention
In view of this, the embodiment of the present application provides a live feed-back method. The application also relates to a live feed back device, a computing device and a computer readable storage medium, which are used for solving the technical problems of high feed back cost and low cost performance in the prior art.
According to a first aspect of an embodiment of the present application, a live feed-back method is provided, which is applied to a feed-back server, and includes:
receiving a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
searching at least one distribution node of the live stream to be acquired according to the stream identifier;
And determining a target source returning path of the edge node according to the type of at least one distribution node, and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to carry out source returning to obtain the to-be-obtained live stream.
According to a second aspect of the embodiments of the present application, there is provided a live feed-back device, which is applied to a feed-back server, and includes:
the receiving module is configured to receive a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
the searching module is configured to search at least one distribution node of the to-be-acquired live stream according to the stream identification;
and the determining module is configured to determine a target source returning path of the edge node according to the type of the at least one distribution node, and return the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to return to the source to acquire the to-be-acquired live stream.
According to a third aspect of embodiments herein, there is provided a computing device comprising:
a memory and a processor;
the memory is for storing computer-executable instructions, and the processor is for executing the computer-executable instructions to:
Receiving a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
searching at least one distribution node of the live stream to be acquired according to the stream identification;
and determining a target source returning path of the edge node according to the type of at least one distribution node, and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to carry out source returning to obtain the to-be-obtained live stream.
According to a fourth aspect of embodiments herein, there is provided a computer-readable storage medium storing computer-executable instructions that, when executed by a processor, perform the steps of any live feed-back method.
According to the live broadcast source returning method, when a source returning server receives a source returning request sent by an edge node, at least one distribution node of a to-be-acquired live broadcast stream can be searched according to a stream identifier carried in the source returning request, then a target source returning path of the edge node is determined according to the type of the at least one distribution node, and then the target source returning path is returned to the edge node according to a node identifier carried in the source returning request, so that the edge node can return to the source according to the dynamically selected target source returning path and pull the required live broadcast stream. Under the condition, the to-be-acquired live broadcast stream is stored in each distribution node, the type of the distribution node can represent the pulling or pushing condition of the stored to-be-acquired live broadcast stream, the source returning request can be reasonably distributed based on the type of at least one distribution node, the source returning path with higher cost performance is selected, the bandwidth is reasonably utilized, the stream pulling pressure is dispersed, the congestion degree is reduced, the bandwidth waste or the too high bandwidth pressure is avoided, the source returning cost is reduced, namely, the cost performance of the selected target source returning path is higher, the source returning efficiency and the success rate are greatly improved, and the cost is reduced and the efficiency is improved.
Drawings
Fig. 1 is a flowchart of a live feed-back method according to an embodiment of the present application;
fig. 2a is an interaction diagram of a live broadcast process according to an embodiment of the present application;
fig. 2b is a schematic structural diagram of a content distribution network according to an embodiment of the present application;
fig. 3 is a flowchart of another live feed-back method provided by an embodiment of the present application;
fig. 4 is a schematic structural diagram of a live feed back device according to an embodiment of the present application;
fig. 5 is a block diagram of a computing device 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 application relate are explained.
CDN: all are called Content Delivery Network, i.e. Content distribution Network. The CDN is an intelligent virtual network constructed on the basis of the existing network, and by means of edge nodes deployed in various places and through functional modules of dispatching, load balancing, content distribution and the like of a central platform, a user can obtain required content nearby, network congestion is reduced, and the access response speed and hit rate of the user are improved. The most important source station in the CDN network is a data source of the CDN, that is, the most superior backend server, and each machine room node needs to acquire a static file or a real-time multimedia stream from the source station to perform distribution for user access. The edge CDN node is a network edge-side CDN close to the user, and data transmission from the edge CDN node to the user client is referred to as "last kilometer".
First kilometer: the backbone networks on the Internet are very smooth, and only the networks from the user to the last kilometer of the access backbone networks are very unstable, so that most of the network problems are solved.
Returning a source: after the user accesses the backbone network nearby, if the node does not have the required live stream, a pull stream needs to be requested from the superior node, and this behavior is called back source. In the embodiment of the present application, the source station is a server for hosting and uploading live broadcast content in real time, the edge node is a server for a user to finally watch live broadcast, and one or more layers of intermediate source nodes (i.e., secondary source stations) are arranged between the source station and the edge node, which are also called relay servers. When a user accesses an edge node, the edge node may not have a required live stream, and at this time, the edge node needs to make a request to an intermediate source node of an upper layer step by step until a source station to pull a related live stream, which is a source return process.
Streaming media: the media format is a media format played on the Internet in a streaming transmission mode and comprises audio, video and multimedia files; the streaming media does not download the whole file before playing, only stores the initial part into the memory, and caches the data packet when the user accesses the streaming media, so that the media data is correctly output.
Pushing flow: the method comprises the steps that a client side collects video data, and the video data are sent to a streaming media server through coding and network transmission, wherein the server is built by itself or provided by a CDN.
Drawing flow: the client or player downloads or pulls the specified media stream from the server to the local process. In the invention, the back source from the edge CDN node to the stream pushing node corresponds to the edge CDN node to pull the stream from the stream pushing node.
RPC: all called Remote Procedure calls. The client application calls a function or method provided by the server application, requiring the semantics of the call to be expressed and the data of the call to be conveyed over the network.
It should be noted that, in the conventional CDN, a large-scale distribution network is performed through a three-level tree structure of a source station, an intermediate source node, and an edge node. The back source of the CDN node is divided into an IP back source or a domain name back source. The existing CDN node back-source policy is to configure a fixed back-source IP or back-source domain name (if necessary, a port number needs to be matched) in a CDN node system, and a CDN operator may select a closer CDN node as a back-source target in a current node coverage area, or select a third-party CDN with a lower cost as a back-source target.
Because fixed source-returning IP or source-returning domain name is configured, the CDN node cannot consider cost information and network quality information (including data transmission bandwidth, transmission packet loss rate, transmission delay, and the like) of each node in the network, and distribute the node condition of a live stream to be obtained, and cannot ensure that the cost performance of the source-returning is high.
Therefore, the live broadcast source returning method provided by the embodiment of the application calculates a stream pulling path with high stream pulling quality and low required cost for live broadcast source returning of the edge nodes, and can consider real-time information of all CDN rooms and nodes and information of all live streams, so that a stream pulling path with high quality and high cost performance can be provided for source returning, cost is reduced, and efficiency is improved.
The present application provides a live feed-back method, and the present application also relates to a live feed-back device, a computing device, and a computer readable storage medium, which are individually described in detail in the following embodiments.
Fig. 1 shows a flowchart of a live feed-back method provided in an embodiment of the present application, which is applied to a feed-back server, and specifically includes the following steps:
step 102: and receiving a source returning request sent by the edge node, wherein the source returning request carries a stream identifier of the to-be-acquired live stream and a node identifier of the edge node.
Specifically, the edge node may refer to an edge server deployed in each place in the content distribution network, and provides user access capability in the content distribution network. The source returning request refers to a request initiated by the edge node to the source returning server when the to-be-acquired live stream which needs to be acquired by the user does not exist in the edge node, and the source returning request can carry the stream identifier of the to-be-acquired live stream and the node identifier of the edge node, so that the source returning server can return a source returning path which can acquire the to-be-acquired live stream to the edge node.
The back-to-source server may be a server capable of providing back-to-source service, that is, a server capable of receiving a back-to-source request sent by an edge node, determining a path for performing back-to-source, and returning to the edge node; the stream identifier of the to-be-acquired live stream can uniquely identify the to-be-acquired live stream, and for example, the stream identifier of the to-be-acquired live stream can be the stream name uuid of the to-be-acquired live stream; the node ID of an edge node may uniquely identify an edge node, for example, the node ID may be a node ID of the edge node.
Fig. 2a is an interaction diagram of a live broadcast process according to an embodiment of the present application, where a user terminal may send an access request to a scheduling server, the scheduling server may select a target edge node from edge nodes distributed in various regions of a Content Delivery Network (CDN) to allocate the target edge node to the user terminal (return an address of the target edge node to the user terminal), the user terminal may send a streaming request to the target edge node based on the address of the target edge node, and after receiving the streaming request, the target edge node should send a corresponding live broadcast to the user terminal. If the target edge node does not have the corresponding live stream, the target edge node may send a source returning request to the source returning server, the source returning server may provide a source returning service, and return a corresponding source returning path to the target edge node (e.g., from the target edge node to a first middle source node on the left side and then to the source station), and the target edge node may pull the corresponding live stream from the source station based on the received source returning path and push the live stream to the user side.
In practical applications, the source-returning server may start a server-side service of a Remote Procedure Call (RPC). Specifically, the interface may select an HTTP (HyperText Transfer Protocol) mode, analyze request information of a source return request sent by the edge node, obtain a stream identifier of the to-be-acquired live stream and a node identifier of the edge node,
it should be noted that, after a user enters a certain live broadcast room through a viewer to request the central scheduling server to allocate an edge node, the viewer of the user may pull a stream to the allocated edge node, and when the edge node has no live broadcast stream of the live broadcast room, a source return is required, and at this time, the edge node may send a source return request to a source return server, where the source return request carries a stream identifier of the live broadcast stream of the live broadcast room.
For example, fig. 2b shows a schematic structural diagram of a content distribution network provided according to an embodiment of the present application, and as shown in fig. 2b, the content distribution network includes a source station: ROOT, intermediate source node: l1-01, L1-02, edge node: l2-01, L2-02, L2-03 and L2-04. Each anchor can push the corresponding live stream to the source station ROOT through the anchor terminal held by the anchor. Suppose that the audience member a enters a live broadcast room of the anchor a, the edge node allocated to the audience member a by the content distribution network is L2-01, and the edge node L2-01 does not have a live broadcast stream a corresponding to the anchor a, at this time, the edge node L2-01 may send a source return request to the source return server, where the source return request carries a stream identifier of the live broadcast stream a.
In the embodiment of the application, when the to-be-acquired live stream which needs to be acquired by the user does not exist in the edge node, the source returning request can be sent to the source returning server, and the source returning server can receive the source returning request of the edge node, so that the corresponding source returning path is determined to return to the edge node in the subsequent process, the edge node can acquire the required live stream, and the live stream which the user wants to watch can be successfully pulled.
In an optional implementation manner of this embodiment, a zero-hop reference path and a one-hop reference path with higher cost performance between all nodes in the content distribution network may be pre-calculated and stored, so as to facilitate subsequent direct query, that is, before receiving a back-to-source request sent by an edge node, the method may further include:
acquiring cost information and network parameter information between every two nodes in a content distribution network;
calculating the link score between every two nodes according to the cost information and the network parameter information between every two nodes;
determining a reference zero-hop path and a reference one-hop path from the edge node to each other node in the content distribution network according to the link score, wherein the reference zero-hop path is that the edge node is directly connected with other nodes, and the reference one-hop path is that a relay node exists between the edge node and other nodes;
And correspondingly storing the reference zero-hop path and the reference one-hop path with the corresponding starting node and the corresponding terminating node, and constructing a reference path library of the content distribution network.
Specifically, the cost information is information for evaluating the cost of bandwidth between every two nodes, such as the cost required to be consumed by unit bandwidth between every two nodes; the network parameter information is information for evaluating a network environment between every two nodes, the network parameter information includes at least one of network bandwidth, packet loss rate, round-trip delay, node congestion degree and the like of a machine room where the nodes are located, and the network parameter information between the two nodes can indicate the network environment between the two nodes.
It should be noted that the machine room in which each node in the content distribution network is located can send a test message to the machine rooms in which other nodes are located, so as to test the network conditions of the machine room, such as packet loss rate, network delay, and the like; in addition, each node in the content distribution network can also acquire the current network bandwidth in real time and the frequency information currently selected as the return-source path, and then the node can report the network parameter information such as the network condition obtained by testing, the network bandwidth acquired in real time, the frequency information currently selected as the return-source path (namely the node congestion degree) and the like to the basic information server, and the network parameter information of each node in the content distribution network is stored through the basic information server.
In addition, the link score is obtained by calculation based on the cost information and the network parameter information, so that the cost and the quality can be balanced, that is, the link score can represent the transmission cost performance between every two nodes, and the higher the link score is, the higher the transmission cost performance between the two nodes is, the higher the probability that the link between the two nodes is selected is.
In an optional implementation manner of this embodiment, the cost information includes at least one cost parameter, and the network parameter information includes at least one network parameter, so that a link score between each two nodes is calculated according to the cost information and the network parameter information between each two nodes, and a specific implementation process may be as follows:
determining each cost parameter in the cost information and each network parameter in the network parameter information;
respectively determining each cost parameter and the parameter score corresponding to each network parameter based on the corresponding relation between the preset parameters and the scores;
and determining the link score between the two nodes according to the obtained parameter scores.
It should be noted that, when different cost parameters and network parameters are located in different numerical ranges, corresponding scores are set, so that parameter scores corresponding to the cost parameters and the network parameters can be determined respectively based on the preset corresponding relationship between the parameters and the scores, and then, a link score between the two nodes can be determined according to the parameter scores.
In practical application, when determining the link score between two nodes according to each parameter score, the parameter average score corresponding to each parameter score can be determined, and the parameter average score is used as the link score between the two nodes. Or setting a weight coefficient of each parameter according to the influence degree of each parameter in the cost information and the network parameter information on the actual access quality, determining a parameter weighted average score corresponding to each parameter score based on each parameter score and the corresponding weight coefficient, and taking the parameter weighted average score as a link score between the two nodes.
In addition, weighting coefficients of parameters (cost required to be consumed by unit bandwidth, network bandwidth, packet loss rate, round-trip delay, node congestion degree and the like) in the cost information and the network parameter information can be determined based on AI (artificial intelligence), and then weighting and fusing the scores of the parameters to obtain a link score between two nodes.
The corresponding relation between the parameters and the scores can be determined based on the attributes of the parameters, for example, the lower the cost required to be consumed by the unit bandwidth, the higher the corresponding score; the higher the network bandwidth is, the higher the corresponding score is; the lower the packet loss rate is, the higher the corresponding score is; the lower the round-trip delay, the higher the corresponding score; the lower the congestion degree of the node is, the higher the corresponding score is.
In addition, the reference to the zero-hop path refers to that the edge node is directly connected to other nodes, and no relay node exists, such as path 3 in fig. 2 b. In addition, the edge node is directly connected with a certain node and should correspond to a zero-hop path, but in practical application, services in the node can be provided by different operators, and the cost for providing the services by the different operators is different, so that the link score between the edge node and each operator of the node can be determined when the edge node is directly connected with the certain node, and the path with the highest link score is selected as a reference zero-hop path from the edge node to the node.
Furthermore, the reference one-hop path refers to a relay node (i.e., an intermediate source node) existing between an edge node and other nodes, such as path 1 and path 2 in fig. 2b, so that the reference one-hop path is composed of two links, from the edge node to the relay node, and from the relay node to other nodes, so that the link scores from the edge node to the relay node, and from the relay node to other nodes can be summed, and the link score of the candidate one-hop path between the edge node and the relay node and between the other nodes can be obtained .
It should be noted that, the benefit of using the zero-hop path is to reduce the delay of the downstream edge node in pulling the flow from the upstream push flow node; the advantage of adopting one-hop path is to avoid the upstream stream-pushing node from generating multiple downlink bandwidths, that is, the downlink bandwidth of the upstream node is borne by the relay node, and the upstream node only needs to transmit the stream media data to the relay node; the reason for not using a multi-hop path is to avoid too high a delay for the requesting node to pull the flow.
In practical application, after reference zero-hop paths and reference one-hop paths between edge nodes and other nodes in the content distribution network are determined according to the link scores, the reference zero-hop paths and the reference one-hop paths can be correspondingly stored with corresponding start nodes and end nodes to construct a reference path library of the content distribution network, and the corresponding reference zero-hop paths and the corresponding reference one-hop paths can be directly inquired from the reference path library based on the start nodes and the end nodes.
In the embodiment of the application, the link score between every two nodes can be calculated based on the cost information and the network parameter information between every two nodes, so that a reference zero-hop path and a reference one-hop path between an edge node and each other node in a content distribution network are determined, a reference path library is constructed, corresponding reference zero-hop paths and reference one-hop paths can be directly inquired from the reference path library based on a starting node and a terminating node, the searched reference zero-hop paths and the searched reference one-hop paths are dynamically determined and obtained based on the cost information and the network parameter information of the nodes, a pull path with high pull flow quality and low cost is provided for the edge node based on the cost information and the network parameter information of the nodes, a source return path with better source return conditions can be returned to the edge node subsequently, the bandwidth is reasonably utilized, the bandwidth waste or the excessive bandwidth pressure is avoided, the source returning efficiency and the success rate are greatly improved, and the cost is reduced and the efficiency is improved.
In an optional implementation manner of this embodiment, a reference zero-hop path and a reference one-hop path may be selected based on the sorting result, that is, the reference zero-hop path and the reference one-hop path between the edge node and each other node in the content distribution network are determined according to the link score, and a specific implementation process may be as follows:
the method comprises the steps that the link scores of candidate one-hop paths between edge nodes and first distribution nodes are sorted according to the distance from the edge nodes to the first distribution nodes, wherein the first distribution nodes are any one of at least one distribution node;
and selecting a preset number of candidate one-hop paths as reference one-hop paths in the sorting result according to a preset selection rule.
Specifically, the preset selection rule is a preset rule for selecting candidate one-hop paths from the sorting result as reference one-hop paths, and the preset selection rule may be for selecting a preset number of candidate one-hop paths sorted in the front, or for selecting a preset number of candidate one-hop paths with a score value larger than a score threshold, or for selecting a preset number of candidate one-hop paths within a preset sorting range. In addition, the preset number refers to the number of preset target source return paths, and for example, the preset number may be 1, 2, 3, and the like.
It should be noted that the link score of each candidate one-hop path between the edge node and the first distribution node may represent cost performance such as cost condition, network condition, etc. of each candidate one-hop path, and the higher the score is, the lower the cost is represented and the higher the network condition is, that is, the higher the cost performance is, so that the scores of each candidate one-hop path may be sorted from high to low, and according to a preset selection rule, a preset number of candidate one-hop paths are selected as reference one-hop paths in a sorting result, so that a path with better cost performance is dynamically selected as a source return path and returned to the edge node, thereby greatly improving the source return efficiency and success rate, and reducing cost and improving efficiency.
Furthermore, in addition to selecting the reference one-hop path based on the above-mentioned ranking result of the link scores of each candidate one-hop path between the edge node and the first distribution node, since each node in the content distribution network can form a multi-source directed graph and each node in the content distribution network is a node in the multi-source directed graph, the link score between every two nodes in the content distribution network can be used as a weight value of an edge between the two nodes, then based on a shortest path algorithm, the shortest path between the edge node and each other node is obtained, and the shortest path is used as a reference zero-hop path or a reference one-hop path. The shortest path algorithm may be Dijkstra algorithm (dickstra algorithm) or Floyd algorithm (freoud algorithm).
In an optional implementation manner of this embodiment, the updating the constructed reference path library at regular time may further include, that is, after the constructing the reference path library of the content distribution network, the:
acquiring updating cost information and updating network parameter information between every two nodes in a content distribution network in the current period by taking preset duration as a period;
and updating the reference path library of the content distribution network according to the updating cost information and the updating network parameter information.
Specifically, the preset time duration may be a preset time duration, which represents a period for periodically updating the reference path library, such as 0.5 second, 1 second, 10 seconds, and the like.
It should be noted that the update cost information and the update network parameter information between every two nodes in the content distribution network in the current period can be obtained every preset time, the reference path library of the content distribution network is updated according to the update cost information and the update network parameter information, and the constructed reference path library is periodically updated, so that the reference zero-hop path and the reference one-hop path in the reference path library can be dynamically updated based on the real-time cost information and the real-time network parameter information, the method can adapt to the real-time changing network environment, the accuracy of the reference path library is ensured, and the accuracy of the subsequently determined target back-to-source path is ensured.
Step 104: and searching at least one distribution node of the live stream to be acquired according to the stream identification.
It should be noted that the at least one distribution node of the to-be-acquired live stream refers to stream distribution information of the to-be-acquired live stream, that is, distribution information of each live stream in the content distribution network, where the stream distribution information may be stored in a form of a stream forwarding tree, one live stream corresponds to one stream forwarding tree, and each node in the stream forwarding tree is a distribution node in which the live stream is stored.
The flow forwarding tree is a multi-branch tree, and a root node in the flow forwarding tree is a node with a child node in a tree structure, such as a flow pushing node in a content distribution network, namely a source station; the leaf node is a node in the tree structure where a parent node exists, such as a pull flow node in the content distribution network, i.e., an intermediate source node, an edge node, and the like.
It should be noted that after a node in the content distribution network pulls a live stream, the pulled live stream can be stored locally in the node, and subsequently, if the same live stream needs to be pulled again, the node can directly pull the live stream from the node, and the node can report the stored live stream information to the stream information server.
In practical application, after receiving a source returning request sent by an edge node, a source returning server may obtain corresponding stream distribution information from a stream information server according to a stream identifier of a to-be-obtained live stream carried in the source returning request, obtain at least one distribution node of the to-be-obtained live stream according to the stream distribution information, and determine which nodes in a content distribution network store the to-be-obtained live stream.
In an optional implementation manner of this embodiment, if at least one distribution node of the to-be-acquired live stream is not searched, the method may directly return the source to the source station, that is, after searching for the at least one distribution node of the to-be-acquired live stream according to the stream identifier, further include:
and under the condition that at least one distribution node of the live stream to be acquired is not found, searching a reference one-hop path from the edge node to the source station from a reference path library to be used as a target source return path of the edge node.
It should be noted that if at least one distribution node of the to-be-acquired live stream is not found, it indicates that no node in the content distribution network has pulled the to-be-acquired live stream, that is, the to-be-acquired live stream is not stored in each node in the content distribution network, and if the to-be-acquired live stream is a live stream corresponding to a newly-played anchor, the source can be directly returned to the source station.
In practical application, if a large number of edge nodes directly return to the source station, the pressure of the source station may be too high, and therefore, under the condition that at least one distribution node of a to-be-acquired live stream is not found, a reference zero-hop path from an edge node to the source station is not selected, but a reference one-hop path from the edge node to the source station is found from a reference path library to serve as a target return path of the edge node, so that sudden increase of downlink bandwidth of an upstream plug flow node (i.e., the source station) caused by a sudden increase of user requests is avoided, and the service pressure is too high or the live stream is down.
Step 106: and determining a target back-to-source path of the edge node according to the type of at least one distribution node.
It should be noted that, if at least one distribution node of the to-be-acquired live stream is found, it is indicated that some nodes in the content distribution network have pulled the to-be-acquired live stream, and at this time, the target return path of the edge node may be determined according to the type of the at least one distribution node. The type of the distribution node may represent a position of the distribution node in the flow forwarding tree, so as to indicate a pulling or pushing condition of the stored to-be-acquired live stream, for example, the type of the distribution node may be a root node, a leaf node, an adjacent distribution node, and the like, where the adjacent distribution node is a distribution node in the same machine room as the edge node.
In the embodiment of the application, the live stream to be acquired is stored in each distribution node, the distribution node type can represent the stored pulling or pushing condition of the live stream to be acquired, the source returning request can be reasonably distributed based on the type of at least one distribution node, so that the source returning path with higher cost performance is selected, the bandwidth is reasonably utilized, the stream pulling pressure is dispersed, the congestion degree is reduced, the bandwidth waste or the bandwidth pressure is avoided being too large, the source returning cost is reduced, the cost performance of the selected target source returning path is higher, the source returning efficiency and the success rate are greatly improved, and the cost is reduced and the efficiency is improved.
In an optional implementation manner of this embodiment, it may also be determined in advance whether the edge node that requests to return to the source stores the live stream to be acquired, that is, before determining the target return-to-source path of the edge node according to the type of the at least one distribution node, further include:
determining whether an edge node is located in at least one distribution node;
if the target return path is located in at least one distribution node, determining that the target return path of the edge node is an empty path;
if the node is not located in at least one distribution node, the operation step of determining the target back-to-source path of the edge node according to the type of the at least one distribution node is executed.
It should be noted that, at least one distribution node refers to a node storing a to-be-acquired live stream in the content distribution network, and if the edge node is located in the at least one distribution node, it indicates that the edge node has already pulled the to-be-acquired live stream, and a source return is not required to be pulled again from other nodes, so that a target source return path of the edge node can be determined to be an empty path at this time; if the edge node is not located in the at least one distribution node, it indicates that the edge node has not pulled the live stream to be acquired before, and a source return is required to be pulled from other nodes, so that a source return path needs to be determined at this time, that is, an operation step of determining a target source return path of the edge node according to the type of the at least one distribution node is performed.
In the embodiment of the application, if the edge node is located in the at least one distribution node, it may be determined that the target back-to-source path of the edge node is an empty path, and only if the edge node is not located in the at least one distribution node, an operation step of determining the target back-to-source path of the edge node according to the type of the at least one distribution node is performed, so that the edge node is prevented from pulling the same live stream for multiple times, and the bandwidth of the edge node is saved.
In an optional implementation manner of this embodiment, at least one distribution node is of a tree structure, that is, at least one distribution node stores in a form of a flow forwarding tree, and at this time, according to a type of the at least one distribution node, a target back-to-source path of an edge node is determined, which may be implemented as follows:
determining whether at least one distribution node only has a root node, wherein the root node is a stream pushing node in a content distribution network;
under the condition that only a root node exists in at least one distribution node, searching a reference one-hop path from the edge node to the root node in at least one distribution node from a reference path library to serve as a target source returning path of the edge node;
and under the condition that nodes except the root node exist in at least one distribution node, determining whether an adjacent distribution node exists in the at least one distribution node, if so, searching a reference zero-hop path from the edge node to the adjacent distribution node from a reference path library to be used as a target return-to-source path of the edge node, wherein the adjacent distribution node is a distribution node in the same machine room as the edge node.
It should be noted that the stream forwarding tree is a multi-branch tree, the leaf nodes in the stream forwarding tree are child nodes of the root node, and when only the root node exists in at least one distribution node, it is indicated that only the root node pulls the live stream to be acquired, so that a reference one-hop path from the edge node to the root node can be searched from a reference path library to serve as a target source return path of the edge node.
In practical application, only the root node in at least one acquired distribution node stores a live stream to be acquired, and if a large number of edge nodes directly return to the root node, the pressure of the root node may be too high, so that under the condition that only the root node exists, a reference zero-hop path from the edge node to the root node is not selected, but a reference one-hop path from the edge node to the root node is searched from a reference path library to serve as a target source return path of the edge node, and the condition that the service pressure is too high or the service downtime is caused due to sudden increase of downlink bandwidth of an upstream stream pushing node (namely, the root node) caused by sudden increase of user requests is avoided.
In addition, under the condition that nodes except a root node exist in at least one distribution node, the fact that a plurality of nodes pull the live stream to be acquired is indicated, the edge node can acquire the live stream to be acquired from the plurality of nodes, therefore, at this time, whether an adjacent distribution node exists in at least one distribution node can be determined, the adjacent distribution node is a distribution node which is located in the same machine room with the edge node, if the adjacent distribution node exists, a reference zero-hop path from the edge node to the adjacent distribution node can be searched from a reference path library and used as a target source return path of the edge node, and therefore the edge node can directly pull the live stream to be acquired from the distribution nodes in the same machine room, and pulling cost and time are reduced. The reference zero-hop path from the edge node to the adjacent distribution node corresponds to an intranet IP path in the computer room.
It should be noted that the edge nodes in the content distribution network are nodes that are distributed in the machine rooms of each area and provide services to users, and one machine room of each area is often provided with a plurality of edge nodes, that is, there are a plurality of edge nodes located in the same machine room in the content distribution network. At least one distribution node is a node which pulls the required live stream, so that whether an adjacent distribution node exists in at least one distribution node can be determined, namely whether the same machine room node of the edge node which initiates the back-source request pulls the corresponding live stream once is determined, if yes, the back-source can be directly carried out from the same machine room node, and the pulling cost and time are reduced.
In addition, only the edge node in the same machine room returns the source to the adjacent distribution node to pull the live stream to be acquired, and the probability of sudden increase of the user request is low, so that a reference zero-hop path from the edge node to the adjacent distribution node can be selected as a target source returning path of the edge node, and the stream pulling delay is reduced.
In an optional implementation manner of this embodiment, if there is no adjacent distribution node in the at least one distribution node, determining a target back-to-source path by further combining the type of the to-be-acquired live broadcast stream, that is, after determining whether there is an adjacent distribution node in the at least one distribution node, may further include:
Determining the number of stream watching persons corresponding to at least one distribution node under the condition that the adjacent distribution node does not exist in the at least one distribution node;
and determining a target back-to-source path of the edge node according to the number of the stream watching persons.
It should be noted that the number of stream watching persons of the to-be-acquired live stream may represent the current playing amount of the to-be-acquired live stream, and the number of source return skip revolutions of the source return path may be controlled by the number of stream watching persons of the to-be-acquired live stream, where the source return skip number includes zero skip and one skip, that is, whether the relay node passes through between the edge node and the upstream stream push node is determined.
In practical application, the Real-Time Streaming Protocol adopted by each node for pulling the stream can be selected from a Real-Time Messaging Protocol (RTMP), an adaptive Streaming Protocol (HTTP Live Streaming), and the like, and according to the number of people watching the stream, it can be determined whether the Live stream to be obtained is cold stream or hot stream, which indicates that the number of people pulling the Live stream to be obtained is large, if zero-hop is adopted, multiple downlink bandwidths may be generated at the upstream stream pushing node, and the pressure at the upstream stream pushing node is too large, so that a one-hop path can be selected at this Time, and multiple downlink bandwidths generated at the upstream stream pushing node are avoided, that is, the downlink bandwidths of the upstream stream pushing node are borne by the relay node, and the upstream stream pushing node only needs to transmit the stream media data of the Live stream to be obtained to the relay node.
In addition, cold flow indicates that the number of people pulling the live broadcast stream to be acquired is small, the downlink bandwidth generated by the upstream stream pushing node is small, and if a one-hop path is adopted, stream pulling delay can be caused, so that a zero-hop path can be selected at the moment, and the delay of the downstream edge node in pulling the stream from the upstream stream pushing node is reduced.
In an optional implementation manner of this embodiment, it may be determined whether the live stream to be obtained is cold stream or hot stream according to the number of people who watch the stream and a number threshold, that is, according to the number of people who watch the stream, a target source return path of the edge node is determined, and a specific implementation process may be as follows:
under the condition that the number of the stream viewers is smaller than the threshold value of the number of people, reference zero-jump paths from the edge nodes to all the distribution nodes are determined, and target source return paths of the edge nodes are determined according to the link values of all the reference zero-jump paths;
and under the condition that the number of the stream viewers is more than or equal to the threshold value of the number of the stream viewers, determining a reference one-hop path from the edge node to each distribution node, and determining a target source returning path of the edge node according to the link value of each reference one-hop path.
It should be noted that, when the number of viewers is less than the threshold, it is indicated that the live broadcast stream to be acquired is cold, the number of viewers is small, and a zero-hop path should be used for returning to the source, so that the reference zero-hop paths from the edge nodes to the distribution nodes can be traversed, and the target return path of the edge node is determined according to the link scores of the reference zero-hop paths. The reference zero-hop paths from the edge nodes to the distribution nodes can be obtained from a reference path library constructed in advance.
In practical application, when determining a target back-to-source path of an edge node according to the link scores of each reference zero-hop path, the link scores of each reference zero-hop path may be sorted, a preset number of reference zero-hop paths are selected from the sorting result according to a preset rule as the target back-to-source paths, and if the highest link score is selected from each reference zero-hop path as the target back-to-source path.
In addition, under the condition that the number of people watching the live broadcast is larger than or equal to the threshold number of people, the live broadcast to be obtained is heat flow, the number of people watching the live broadcast is large, and a one-hop path is adopted for returning the source, so that a reference one-hop path from the edge node to each distribution node can be traversed at the moment, and the target source returning path of the edge node is determined according to the link value of each reference one-hop path. The reference one-hop path from the edge node to each distribution node can be obtained from a reference path library constructed in advance.
In practical applications, when determining the target back-to-source path of the edge node according to the link scores of the reference one-hop paths, the process of determining the target back-to-source path of the edge node according to the link scores of the reference zero-hop paths may be similar to that described above.
In the embodiment of the application, the source return jump revolution number can be determined according to the number of stream watching persons to acquire the live stream, the selected target source return path combines the distribution nodes and the number of stream watching persons to acquire the live stream in the stream distribution information, and the number of stream watching persons to acquire the live stream, stream delay, downlink bandwidth and the like are comprehensively considered, so that the selected target source return path with the excellent source return performance price returns to the edge node, the source return efficiency and the success rate are greatly improved, and the cost is reduced and the efficiency is improved.
Step 108: and returning a target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to return the source to acquire the live stream to be acquired.
It should be noted that, after determining the target source return path corresponding to the source return request, the source return server may return the target source return path to the edge node through the RPC interface, so that the edge node may return the source according to the target source return path to obtain the required live stream to be obtained.
According to the live broadcast source returning method, a reference zero-hop path and a reference one-hop path from the edge node to each other node can be determined in advance based on cost information and network parameter information between every two nodes, a reference path library is constructed, and then the corresponding reference zero-hop path and the reference one-hop path can be directly inquired from the reference path library based on the starting node and the ending node. When the source returning server receives a source returning request sent by an edge node, at least one distribution node of a to-be-acquired live stream can be searched according to a stream identifier carried in the source returning request, then a target source returning path of the edge node is determined from a pre-constructed reference path library according to the type of the at least one distribution node, and then the target source returning path is returned to the edge node according to a node identifier carried in the source returning request, so that the edge node can return to the source according to the dynamically selected target source returning path and pull the required live stream.
Under the condition, the to-be-acquired live stream is stored in each distribution node, the type of the distribution node can represent the pulling or pushing condition of the stored to-be-acquired live stream, the source returning request can be reasonably distributed based on the type of at least one distribution node, the source returning path with higher cost performance is selected, the bandwidth is reasonably utilized, the stream pulling pressure is dispersed, the congestion degree is reduced, the bandwidth waste or the bandwidth pressure is avoided being overlarge, the source returning cost is reduced, namely, the cost performance of the selected target source returning path is higher, the source returning efficiency and the success rate are greatly improved, and the cost is reduced and the efficiency is improved.
Fig. 3 shows a flowchart of another live feed-back method provided in an embodiment of the present application, which is applied to a feed-back server, and specifically includes the following steps:
step 302: and determining a reference zero-hop path and a reference one-hop path from the edge node to each other node in the content distribution network according to the cost information and the network parameter information between every two nodes, and constructing a reference path library of the content distribution network.
The reference zero-hop path refers to direct connection between the edge node and other nodes, and the reference one-hop path refers to a relay node existing between the edge node and other nodes.
Step 304: and receiving a source returning request sent by the edge node, wherein the source returning request carries the stream identifier of the to-be-acquired live stream and the node identifier of the edge node.
Step 306: and searching at least one distribution node of the live stream to be acquired according to the stream identification.
Step 308: determining whether at least one distribution node of the live stream to be acquired is found, if not, executing the following step 310, and if so, executing the following step 312.
Step 310: and searching a reference one-hop path from the edge node to the source station from the reference path library to serve as a target source return path of the edge node.
Step 312: it is determined whether an edge node is located in at least one distribution node, if so, the following step 314 is performed, and if not, the following step 316 is performed.
Step 314: and determining that the target back-source path of the edge node is an empty path.
Step 316: it is determined whether only a root node exists in the at least one distribution node, if not, the following step 318 is performed, and if so, the following step 320 is performed.
Step 318: and searching a reference one-hop path from the edge node to a root node in at least one distribution node from a reference path library to serve as a target source returning path of the edge node.
Step 320: it is determined whether there is an adjacent distribution node in the at least one distribution node, if so, the following step 322 is performed, and if not, the following step 324 is performed.
Step 322: and searching a reference zero-hop path from the edge node to the adjacent distribution node from the reference path library, and taking the reference zero-hop path as a target back-source path of the edge node.
And the adjacent distribution nodes are distribution nodes which are in the same machine room as the edge nodes.
Step 324: it is determined whether the live stream to be acquired is cold, if so, the following step 326 is performed, and if not, the following step 328 is performed.
Step 326: and determining reference zero-hop paths from the edge nodes to the distribution nodes, and determining target return-to-source paths of the edge nodes according to the link scores of the reference zero-hop paths.
Step 328: and determining a reference one-hop path from the edge node to each distribution node, and determining a target return-to-source path of the edge node according to the link value of each reference one-hop path.
Step 330: and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to return the source to acquire the live stream to be acquired.
The live broadcast source returning method provided by the application can determine a reference zero-hop path and a reference one-hop path from the edge node to each other node in advance based on the cost information and the network parameter information between every two nodes, construct a reference path library, and then directly inquire the corresponding reference zero-hop path and the reference one-hop path from the reference path library based on the starting node and the ending node. When the source returning server receives a source returning request sent by an edge node, at least one distribution node of a live stream to be acquired can be searched according to a stream identifier carried in the source returning request, then a target source returning path of the edge node is determined from a pre-constructed reference path library according to the type of the at least one distribution node, and then the target source returning path is returned to the edge node according to a node identifier carried in the source returning request, so that the edge node can return to the source according to the dynamically selected target source returning path and pull the required live stream.
Corresponding to the above method embodiment, the present application further provides a live feed back device embodiment, and fig. 4 shows a schematic structural diagram of a live feed back device provided in an embodiment of the present application. As shown in fig. 4, the apparatus includes:
a receiving module 402, configured to receive a source returning request sent by an edge node, where the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
a searching module 404 configured to search, according to the stream identifier, at least one distribution node of the live stream to be acquired;
the determining module 406 is configured to determine a target back-to-source path of the edge node according to the type of the at least one distribution node, and return the target back-to-source path to the edge node according to the node identifier, where the target back-to-source path is used to instruct the edge node to perform back-to-source acquisition on the live stream to be acquired.
Optionally, the apparatus further comprises a construction module configured to:
acquiring cost information and network parameter information between every two nodes in a content distribution network;
calculating the link score between every two nodes according to the cost information and the network parameter information between every two nodes;
determining a reference zero-hop path and a reference one-hop path from the edge node to each other node in the content distribution network according to the link score, wherein the reference zero-hop path is that the edge node is directly connected with other nodes, and the reference one-hop path is that a relay node exists between the edge node and other nodes;
And correspondingly storing the reference zero-hop path and the reference one-hop path with the corresponding starting node and the corresponding terminating node, and constructing a reference path library of the content distribution network.
Optionally, at least one distribution node is a tree structure; the determination module 406 is further configured to:
determining whether at least one distribution node only has a root node, wherein the root node is a stream pushing node in a content distribution network;
under the condition that only a root node exists in at least one distribution node, searching a reference one-hop path from the edge node to the root node in the at least one distribution node from a reference path library to serve as a target back-to-source path of the edge node;
and under the condition that nodes except the root node exist in at least one distribution node, determining whether an adjacent distribution node exists in the at least one distribution node, if so, searching a reference zero-hop path from the edge node to the adjacent distribution node from a reference path library to be used as a target return-to-source path of the edge node, wherein the adjacent distribution node is a distribution node in the same machine room as the edge node.
Optionally, the determining module 406 is further configured to:
determining the number of stream watching persons corresponding to at least one distribution node under the condition that the adjacent distribution node does not exist in the at least one distribution node;
And determining a target back-to-source path of the edge node according to the number of the stream watching persons.
Optionally, the determining module 406 is further configured to:
under the condition that the number of people who watch the flow is smaller than the threshold value of the number of people, reference zero-jump paths from the edge nodes to all the distribution nodes are determined, and target source returning paths of the edge nodes are determined according to the link values of all the reference zero-jump paths;
and under the condition that the number of the stream viewers is more than or equal to the number threshold, determining a reference one-hop path from the edge node to each distribution node, and determining a target source returning path of the edge node according to the link value of each reference one-hop path.
Optionally, the apparatus further comprises a first execution module configured to:
determining whether the edge node is located in at least one distribution node;
if the target back-to-source path is located in at least one distribution node, determining that the target back-to-source path of the edge node is an empty path;
if the node is not located in at least one distribution node, the operation step of determining the target back-to-source path of the edge node according to the type of the at least one distribution node is executed.
Optionally, the apparatus further comprises a lookup module configured to:
and under the condition that at least one distribution node of the to-be-acquired live stream is not found, searching a reference one-hop path from the edge node to the source station from a reference path library to serve as a target source returning path of the edge node.
Optionally, the apparatus further comprises an update module configured to:
acquiring updating cost information and updating network parameter information between every two nodes in a content distribution network in the current period by taking a preset duration as a period;
and updating the reference path library of the content distribution network according to the updating cost information and the updating network parameter information.
Optionally, the cost information includes at least one cost parameter, and the network parameter information includes at least one network parameter; the build module is further configured to:
determining each cost parameter in cost information and each network parameter in the network parameter information;
respectively determining each cost parameter and a parameter score corresponding to each network parameter based on a preset corresponding relationship between the parameters and the scores;
and determining the link score between the two nodes according to the obtained parameter scores.
Optionally, the building module is further configured to:
the method comprises the steps that the link scores of candidate one-hop paths between edge nodes and first distribution nodes are sorted according to the distance from the edge nodes to the first distribution nodes, wherein the first distribution nodes are any one of at least one distribution node;
And selecting a preset number of candidate one-hop paths as reference one-hop paths in the sorting result according to a preset selection rule.
Optionally, the cost information is information for evaluating bandwidth cost between every two nodes, the network parameter information is information for evaluating a network environment between every two nodes, and the network parameter information includes at least one of network bandwidth, packet loss rate, round-trip delay, and node congestion degree of a computer room where the node is located.
The live broadcast source returning device provided by the application can determine a reference zero-hop path and a reference one-hop path from the edge node to each other node in advance based on cost information and network parameter information between every two nodes, a reference path library is constructed, and corresponding reference zero-hop paths and reference one-hop paths can be directly inquired from the reference path library based on the starting node and the ending node in the follow-up process. When the source returning server receives a source returning request sent by an edge node, at least one distribution node of a to-be-acquired live stream can be searched according to a stream identifier carried in the source returning request, then a target source returning path of the edge node is determined from a pre-constructed reference path library according to the type of the at least one distribution node, and then the target source returning path is returned to the edge node according to a node identifier carried in the source returning request, so that the edge node can return to the source according to the dynamically selected target source returning path and pull the required live stream.
The foregoing is a schematic diagram of a live feed back device in this embodiment. It should be noted that the technical solution of the live broadcast source returning device and the technical solution of the live broadcast source returning method belong to the same concept, and details of the technical solution of the live broadcast source returning device, which are not described in detail, can be referred to the description of the technical solution of the live broadcast source returning method.
Fig. 5 shows a block diagram of a computing device according to an embodiment of the present application. The components of the computing device 500 include, but are not limited to, a memory 510 and a processor 520. Processor 520 is coupled to memory 510 via bus 530, and database 550 is used to store data.
Computing device 500 also includes access device 540, access device 540 enabling computing device 500 to communicate via one or more networks 560. Examples of such networks include a 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. The Access device 540 may include one or more of any type of Network Interface (e.g., a Network Interface Controller (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 application, the above components of the computing device 500 and other components not shown in fig. 5 may also be connected to each other, for example, by a bus. It should be understood that the block diagram of the computing device illustrated in FIG. 5 is for purposes of example only and is not intended to limit the scope of the present application. Other components may be added or replaced as desired by those skilled in the art.
Computing device 500 may be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet computer, personal digital assistant, laptop computer, notebook computer, netbook, etc.), mobile phone (e.g., smartphone), wearable computing device (e.g., smartwatch, smart glasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. Computing device 500 may also be a mobile or stationary server.
Wherein, the processor 520 is configured to execute the following computer-executable instructions:
receiving a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
searching at least one distribution node of the live stream to be acquired according to the stream identifier;
And determining a target source returning path of the edge node according to the type of at least one distribution node, and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to carry out source returning to obtain the to-be-obtained live stream.
The foregoing is a schematic diagram of a computing device of the present embodiment. It should be noted that the technical solution of the computing device and the technical solution of the live broadcast source returning method belong to the same concept, and details that are not described in detail in the technical solution of the computing device can all be referred to in the description of the technical solution of the live broadcast source returning method.
An embodiment of the present application also provides a computer-readable storage medium storing computer-executable instructions that, when executed by a processor, are used to implement the steps of a live feed-back method.
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 belongs to the same concept as the technical solution of the live broadcast source returning method, 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 live broadcast source returning method.
The foregoing description has been directed to specific embodiments of this application. 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, etc. The computer readable medium may include: any entity or device capable of carrying computer program code, recording medium, U-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 media, and the like.
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 foregoing 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 the 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 teaching of this application. The embodiments were chosen and described in order to best explain the principles of the application and its practical application, to thereby enable others skilled in the art to best understand the application and its practical application. The application is limited only by the claims and their full scope and equivalents.

Claims (14)

1. A live broadcast source returning method is applied to a source returning server and comprises the following steps:
receiving a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
searching at least one distribution node of the to-be-acquired live stream according to the stream identifier;
and determining a target source returning path of the edge node according to the type of the at least one distribution node, and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to return to the source to acquire the to-be-acquired live stream.
2. The live feed-back method according to claim 1, wherein before receiving the feed-back request sent by the edge node, the live feed-back method further comprises:
acquiring cost information and network parameter information between every two nodes in a content distribution network;
calculating the link score between each two nodes according to the cost information and the network parameter information between each two nodes;
determining a reference zero-hop path and a reference one-hop path between an edge node and each other node in the content distribution network according to the link score, wherein the reference zero-hop path refers to direct connection between the edge node and the other nodes, and the reference one-hop path refers to a relay node existing between the edge node and the other nodes;
and correspondingly storing the reference zero-hop path and the reference one-hop path with the corresponding starting node and the corresponding terminating node to construct a reference path library of the content distribution network.
3. The live feed back method of claim 2, wherein the at least one distribution node is a tree structure; the determining a target back-to-source path of the edge node according to the type of the at least one distribution node includes:
Determining whether only a root node exists in the at least one distribution node, wherein the root node is a stream pushing node in a content distribution network;
under the condition that only a root node exists in the at least one distribution node, searching a reference one-hop path from the edge node to the root node in the at least one distribution node from the reference path library to serve as a target back-to-source path of the edge node;
and under the condition that nodes except a root node exist in the at least one distribution node, determining whether an adjacent distribution node exists in the at least one distribution node, if so, searching a reference zero-hop path from the edge node to the adjacent distribution node from the reference path library to be used as a target back-to-source path of the edge node, wherein the adjacent distribution node is a distribution node which is in the same machine room as the edge node.
4. The live feed back method of claim 3, wherein after determining whether there is a neighboring distribution node in the at least one distribution node, further comprising:
determining the number of stream viewers corresponding to the at least one distribution node under the condition that the adjacent distribution node does not exist in the at least one distribution node;
And determining a target back-to-source path of the edge node according to the number of the stream viewers.
5. The live feed-back method of claim 4, wherein the determining the target feed-back path of the edge node according to the number of the stream viewers comprises:
determining reference zero-hop paths from the edge nodes to all distribution nodes under the condition that the number of the stream watching people is smaller than the threshold number of people, and determining target source returning paths of the edge nodes according to the link scores of all the reference zero-hop paths;
and under the condition that the number of people for watching the stream is more than or equal to the threshold of the number of people, determining a reference one-hop path from the edge node to each distribution node, and determining a target source returning path of the edge node according to the link score of each reference one-hop path.
6. The live feed-back method according to any one of claims 1-5, wherein before determining the target feed-back path of the edge node according to the type of the at least one distribution node, further comprising:
determining whether the edge node is located in the at least one distribution node;
if the target return path is located in the at least one distribution node, determining that the target return path of the edge node is an empty path;
If the edge node is not located in the at least one distribution node, the operation step of determining the target back-to-source path of the edge node according to the type of the at least one distribution node is executed.
7. The live feed back method as claimed in any one of claims 1 to 5, wherein after searching for the at least one distribution node of the live stream to be acquired according to the stream identifier, the method further comprises:
and under the condition that at least one distribution node of the to-be-acquired live stream is not found, searching a reference one-hop path from the edge node to a source station from a reference path library to serve as a target source returning path of the edge node.
8. The live feed-back method of claim 2, wherein after constructing the reference path library of the content distribution network, further comprising:
acquiring updating cost information and updating network parameter information between every two nodes in the content distribution network in the current period by taking preset duration as a period;
and updating the reference path library of the content distribution network according to the updating cost information and the updating network parameter information.
9. The live feed-back method of claim 2, wherein the cost information comprises at least one cost parameter, and the network parameter information comprises at least one network parameter;
The calculating the link score between every two nodes according to the cost information and the network parameter information between every two nodes includes:
determining each cost parameter in the cost information and each network parameter in the network parameter information;
respectively determining each cost parameter and a parameter score corresponding to each network parameter based on a preset corresponding relationship between the parameters and the scores;
and determining the link score between the two nodes according to the obtained parameter scores.
10. The live feed-back method according to claim 2, wherein the determining, according to the link scores, a reference zero-hop path and a reference one-hop path from an edge node to each other node in the content distribution network comprises:
for the edge node to a first distribution node, sorting the link scores of each candidate one-hop path between the edge node and the first distribution node, wherein the first distribution node is any one of the at least one distribution node;
and selecting a preset number of candidate one-hop paths from the sorting result as the reference one-hop paths according to a preset selection rule.
11. The live feed-back method according to claim 2, wherein the cost information is information for evaluating a bandwidth cost between each two nodes, the network parameter information is information for evaluating a network environment between each two nodes, and the network parameter information includes at least one of a network bandwidth, a packet loss rate, a round trip delay, and a node congestion degree of a computer room where the node is located.
12. A live feed back device is applied to a feed back server and comprises:
the receiving module is configured to receive a back-to-source request sent by an edge node, wherein the back-to-source request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
the searching module is configured to search at least one distribution node of the to-be-acquired live stream according to the stream identification;
a determining module configured to determine a target back-to-source path of the edge node according to the type of the at least one distribution node, and return the target back-to-source path to the edge node according to the node identifier, where the target back-to-source path is used to instruct the edge node to perform back-to-source acquisition on the to-be-acquired live broadcast stream.
13. A computing device, comprising:
a memory and a processor;
the memory is configured to store computer-executable instructions, and the processor is configured to execute the computer-executable instructions to implement the method of:
receiving a source returning request sent by an edge node, wherein the source returning request carries a stream identifier of a to-be-acquired live stream and a node identifier of the edge node;
searching at least one distribution node of the to-be-acquired live stream according to the stream identifier;
and determining a target source returning path of the edge node according to the type of the at least one distribution node, and returning the target source returning path to the edge node according to the node identifier, wherein the target source returning path is used for indicating the edge node to return to the source to acquire the to-be-acquired live stream.
14. A computer-readable storage medium having stored thereon computer-executable instructions which, when executed by a processor, perform the steps of the live feed back method of any of claims 1 to 11.
CN202210324997.0A 2022-03-30 2022-03-30 Live broadcast source returning method and device Active CN114760482B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210324997.0A CN114760482B (en) 2022-03-30 2022-03-30 Live broadcast source returning method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210324997.0A CN114760482B (en) 2022-03-30 2022-03-30 Live broadcast source returning method and device

Publications (2)

Publication Number Publication Date
CN114760482A true CN114760482A (en) 2022-07-15
CN114760482B CN114760482B (en) 2024-02-27

Family

ID=82328448

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210324997.0A Active CN114760482B (en) 2022-03-30 2022-03-30 Live broadcast source returning method and device

Country Status (1)

Country Link
CN (1) CN114760482B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115412737A (en) * 2022-08-30 2022-11-29 上海哔哩哔哩科技有限公司 Method and device for determining live broadcast source return relay node
CN115460427A (en) * 2022-08-26 2022-12-09 上海哔哩哔哩科技有限公司 Live broadcast scheduling method and device, computing equipment and storage medium
CN115643203A (en) * 2022-09-15 2023-01-24 阿里巴巴(中国)有限公司 Content distribution method, content distribution device, content distribution network, device, and medium
CN117834956A (en) * 2023-12-18 2024-04-05 北京联广通网络科技有限公司 Live video acceleration system and method for resource distribution and source return

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2001058237A2 (en) * 2000-02-12 2001-08-16 Hrl Laboratories, Llc Scalable unidirectional routing for mobile ad-hoc networks
CN108200443A (en) * 2017-12-29 2018-06-22 北京奇虎科技有限公司 The distribution method and device of a kind of live TV stream
CN109769023A (en) * 2019-01-16 2019-05-17 网宿科技股份有限公司 A kind of data transmission method, associated server and storage medium
CN111263171A (en) * 2020-02-25 2020-06-09 北京达佳互联信息技术有限公司 Live streaming media data acquisition method and edge node area networking system
CN111385198A (en) * 2018-12-29 2020-07-07 北京华为数字技术有限公司 Path determining method, device and communication system
CN112822105A (en) * 2019-11-15 2021-05-18 华为技术有限公司 Path planning method and device and data transmission system
CN112929676A (en) * 2019-12-06 2021-06-08 北京金山云网络技术有限公司 Live data stream acquisition method, device, node and system
CN113301364A (en) * 2021-01-05 2021-08-24 阿里巴巴集团控股有限公司 Path planning method, CDN connection establishing method, device and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2001058237A2 (en) * 2000-02-12 2001-08-16 Hrl Laboratories, Llc Scalable unidirectional routing for mobile ad-hoc networks
CN108200443A (en) * 2017-12-29 2018-06-22 北京奇虎科技有限公司 The distribution method and device of a kind of live TV stream
CN111385198A (en) * 2018-12-29 2020-07-07 北京华为数字技术有限公司 Path determining method, device and communication system
CN109769023A (en) * 2019-01-16 2019-05-17 网宿科技股份有限公司 A kind of data transmission method, associated server and storage medium
CN112822105A (en) * 2019-11-15 2021-05-18 华为技术有限公司 Path planning method and device and data transmission system
CN112929676A (en) * 2019-12-06 2021-06-08 北京金山云网络技术有限公司 Live data stream acquisition method, device, node and system
CN111263171A (en) * 2020-02-25 2020-06-09 北京达佳互联信息技术有限公司 Live streaming media data acquisition method and edge node area networking system
CN113301364A (en) * 2021-01-05 2021-08-24 阿里巴巴集团控股有限公司 Path planning method, CDN connection establishing method, device and storage medium

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115460427A (en) * 2022-08-26 2022-12-09 上海哔哩哔哩科技有限公司 Live broadcast scheduling method and device, computing equipment and storage medium
CN115460427B (en) * 2022-08-26 2024-03-12 上海哔哩哔哩科技有限公司 Live broadcast scheduling method, device, computing equipment and storage medium
CN115412737A (en) * 2022-08-30 2022-11-29 上海哔哩哔哩科技有限公司 Method and device for determining live broadcast source return relay node
CN115412737B (en) * 2022-08-30 2024-03-08 上海哔哩哔哩科技有限公司 Live broadcast return source relay node determining method and device
CN115643203A (en) * 2022-09-15 2023-01-24 阿里巴巴(中国)有限公司 Content distribution method, content distribution device, content distribution network, device, and medium
CN117834956A (en) * 2023-12-18 2024-04-05 北京联广通网络科技有限公司 Live video acceleration system and method for resource distribution and source return
CN117834956B (en) * 2023-12-18 2024-06-21 北京联广通网络科技有限公司 Live video acceleration system and method for resource distribution and source return

Also Published As

Publication number Publication date
CN114760482B (en) 2024-02-27

Similar Documents

Publication Publication Date Title
CN114760482B (en) Live broadcast source returning method and device
Jiang et al. Multi-agent reinforcement learning based cooperative content caching for mobile edge networks
EP2972957B1 (en) Method and apparatus for implementing distributed content caching in a content delivery network
US10455042B2 (en) Transmitting information across a communications network
CN114501073B (en) Live broadcast source returning method and device
US11395209B2 (en) Content delivery system special network device and special local area network connection, content discovery, data transfer, and control methods
CN113811013B (en) Cluster capacity dynamic adjustment method, device, storage medium and communication system
CN113055692A (en) Data processing method and device
JP5011433B2 (en) Method for determining a pair group in the vicinity of another pair, related server, and analysis apparatus
CN112118177A (en) Method and apparatus for controlling multiple connections to increase data transfer rate
Selimi et al. Integration of an assisted p2p live streaming service in community network clouds
CN115002497A (en) Live broadcast source returning scheduling method and system and source returning server
CN103763206A (en) Network scheduling method and gateway
Vasilakos et al. Towards zero downtime edge application mobility for ultra-low latency 5G streaming
CN111478977B (en) Working method of multimedia network flow analysis system
Huang et al. Budget-aware video crowdsourcing at the cloud-enhanced mobile edge
CN115022660B (en) Parameter configuration method and system for content distribution network
US20210021906A1 (en) Special network device
CN114866790B (en) Live stream scheduling method and device
Dubin et al. A fair server adaptation algorithm for HTTP adaptive streaming using video complexity
Hu et al. A novel video transmission optimization mechanism based on reinforcement learning and edge computing
CN114501053A (en) Live stream acquisition method and device
JPWO2014208617A1 (en) Push type information transmitting apparatus, push type information transmitting method and program
CN115514981A (en) Video stream scheduling system and related product
Jia et al. Modeling and optimization of bandwidth supply performance for cloud-assisted video systems under flash crowd

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