CN114245182B - Live video stream acquisition method and device - Google Patents

Live video stream acquisition method and device Download PDF

Info

Publication number
CN114245182B
CN114245182B CN202111543820.1A CN202111543820A CN114245182B CN 114245182 B CN114245182 B CN 114245182B CN 202111543820 A CN202111543820 A CN 202111543820A CN 114245182 B CN114245182 B CN 114245182B
Authority
CN
China
Prior art keywords
address
live video
intranet
video stream
intranet server
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111543820.1A
Other languages
Chinese (zh)
Other versions
CN114245182A (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 CN202111543820.1A priority Critical patent/CN114245182B/en
Publication of CN114245182A publication Critical patent/CN114245182A/en
Application granted granted Critical
Publication of CN114245182B publication Critical patent/CN114245182B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

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/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/239Interfacing the upstream path of the transmission network, e.g. prioritizing client content requests
    • H04N21/2393Interfacing the upstream path of the transmission network, e.g. prioritizing client content requests involving handling client requests
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1001Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
    • H04L67/1004Server selection for load balancing
    • H04L67/1021Server selection for load balancing based on client or server locations
    • 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/25Management operations performed by the server for facilitating the content distribution or administrating data related to end-users or client devices, e.g. end-user or client device authentication, learning user preferences for recommending movies
    • H04N21/258Client or end-user data management, e.g. managing client capabilities, user preferences or demographics, processing of multiple end-users preferences to derive collaborative data
    • H04N21/25808Management of client data
    • H04N21/25841Management of client data involving the geographical location of the client
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/643Communication protocols
    • H04N21/64322IP

Landscapes

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

Abstract

The application discloses a live video stream acquisition method. The method comprises the following steps: responding to a playing request of a live video, and acquiring a playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field; performing domain name resolution on the intranet domain name in the play address to obtain an IP address of an intranet server; accessing the intranet server through the IP address, sending the playing address to the intranet server, analyzing the playing address by the intranet server to obtain a back source identifier contained in the back source identification field, and pulling the live video stream to an edge computing node corresponding to the live video stream by the intranet server according to the back source identifier; and receiving the live video stream returned by the intranet server. The application can increase the bearing number.

Description

Live video stream acquisition method and device
Technical Field
The present application relates to the field of video technologies, and in particular, to a method and an apparatus for acquiring a live video stream.
Background
Inside an enterprise, there is some internal training, or some online meetings, which typically require privacy to keep the content secret. To achieve privacy, live broadcast to the intranet is often used to achieve internal training or online conferences, etc.
In the prior art, intranet live broadcast is generally realized by constructing a streaming media server, so that a whole set of live broadcast flow of live broadcast content acquisition, distribution and watching is realized in a local area network. However, the inventor found that the manner of building the streaming media server is that since the intranet server is fixed, the employee can only pull the fixed intranet server through the live client. Although the live client can pull streams from the fixed intranet server, the fixed intranet server can limit the number of stream carried by the live client, and therefore the number of staff simultaneously pulling streams is limited.
Disclosure of Invention
In view of the foregoing, a live video stream acquisition method, apparatus, system, computer device and computer readable storage medium are provided to solve the problem that the current live video stream acquisition method has larger stream number limitation for carrying out the bearing at the same time.
The application provides a live video stream acquisition method, which comprises the following steps:
responding to a playing request of a live video, and acquiring a playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field;
performing domain name resolution on the intranet domain name in the play address to obtain an IP address of an intranet server;
Accessing the intranet server through the IP address, sending the playing address to the intranet server, analyzing the playing address by the intranet server to obtain a back source identifier contained in the back source identification field, and pulling the live video stream to an edge computing node corresponding to the live video stream by the intranet server according to the back source identifier;
and receiving the live video stream returned by the intranet server.
Optionally, the responding to the playing request of the live video, and acquiring the playing address of the live video includes:
responding to a play request of a live video, and acquiring a play address of the live video from a preset scheduling service request;
and receiving the play address of the live video returned by the scheduling service according to the position information of the user terminal.
Optionally, the performing domain name resolution on the intranet domain name in the play address to obtain an IP address of the intranet server includes:
acquiring IP addresses of a plurality of intranet servers corresponding to the intranet domain name;
and selecting one IP address from the IP addresses of the intranet servers according to a preset selection rule as the IP address of the intranet server obtained by analysis.
Optionally, the intranet server analyzing the play address to obtain a source-returning identifier contained in the source-returning identifier field, and pulling the live video stream to an edge computing node corresponding to the live video stream according to the source-returning identifier includes:
the intranet server extracts the source-returning identification field from the play address;
the intranet server analyzes the source-returning identification field to obtain a source-returning identifier;
the intranet server acquires the IP address of the edge computing node associated with the back source identifier according to the back source identifier;
and the intranet server accesses the edge computing node through the IP address and pulls the live video stream from the edge computing node.
Optionally, the obtaining, by the intranet server, the IP address of the edge computing node associated with the back source identifier according to the back source identifier includes:
the intranet server acquires an IP address of an edge computing node associated with the source return identifier from a preset identifier acquisition service request;
and the intranet server receives the IP address of the edge computing node returned by the identifier acquisition service according to the source return identifier.
Optionally, after the step of accessing the intranet server through the IP address and sending the play address to the intranet server, the method further includes:
the intranet server judges whether the live video stream exists in a local memory or not;
if the live video stream exists in the local memory, returning the live video stream;
if the live video stream does not exist in the local memory, the intranet server analyzes the play address to obtain a source-returning identifier contained in the source-returning identification field, and pulls the live video stream to a corresponding edge computing node according to the source-returning identifier.
Optionally, the live video stream is pushed to an edge computing node by a push terminal through a wide area network.
Optionally, the back source identifier is an identification for uniquely locating an edge node server for storing live video streams.
The application also provides a live video stream acquisition device, which comprises:
the response module is used for responding to the playing request of the live video and obtaining the playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field;
the resolution module is used for carrying out domain name resolution on the intranet domain name in the play address to obtain the IP address of the intranet server;
The access module is used for accessing the intranet server through the IP address, sending the playing address to the intranet server, enabling the intranet server to analyze the playing address to obtain a back source identifier contained in the back source identification field, and enabling the intranet server to pull the live video stream to an edge computing node corresponding to the live video stream according to the back source identifier;
and the receiving module is used for receiving the live video stream returned by the intranet server.
The application also provides a computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the above method when executing the computer program.
The application also provides a live video stream acquisition system, which comprises:
the push terminal is used for pushing the live video stream to the edge computing node;
the edge computing node is used for storing the live video stream;
the user terminal is used for responding to a playing request of the live video and obtaining a playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field; performing domain name resolution on the intranet domain name in the play address to obtain an IP address of an intranet server; accessing the intranet server through the IP address, and sending the playing address to the intranet server; receiving a live video stream returned by the intranet server;
And the intranet server is used for analyzing the playing address to obtain a source-returning identifier contained in the source-returning identification field, pulling the direct-broadcasting video stream to the edge computing node according to the source-returning identifier, and returning the pulled direct-broadcasting video stream to the user terminal.
The application also provides a computer readable storage medium having stored thereon a computer program which when executed by a processor performs the steps of the above method.
According to the video stream acquisition method, the live video stream is acquired according to the intranet domain name and the source-back identification field, so that the live video stream can be directly pushed to the edge computing node, and the live video stream is acquired in a mode of pulling the source-back stream of the intranet server, thereby avoiding the intranet live server from being fixed, realizing flexible deployment of the intranet server, improving the stream bearing capacity and improving the safety.
Drawings
Fig. 1 is a architecture diagram of a live video stream acquisition system of a live video stream acquisition method according to an embodiment of the present application;
fig. 2 is a flowchart of an embodiment of a live video streaming acquisition method according to the present application;
fig. 3 is a detailed flowchart of a step of acquiring a play address of a live video in response to a play request of the live video in an embodiment of the present application;
Fig. 4 is a schematic flowchart of a step of performing domain name resolution on an intranet domain name in the play address to obtain an IP address of an intranet server according to an embodiment of the present application;
fig. 5 is a detailed flowchart of a step in which an intranet server parses the play address to obtain a source-back identifier included in the source-back identifier field, and pulls a direct-broadcast video stream to a corresponding edge computing node according to the source-back identifier in an embodiment of the present application;
FIG. 6 is a flowchart illustrating a refinement of an intranet server according to an embodiment of the present application, wherein the intranet server obtains an IP address of an edge computing node associated with the echo source identifier according to the echo source identifier;
fig. 7 is a flowchart of another embodiment of a live video streaming acquisition method according to the present application;
fig. 8 is a program module diagram of an embodiment of a live video streaming acquisition device according to the present application;
fig. 9 is a schematic hardware structure of a computer device for executing a live video stream acquisition method according to an embodiment of the present application.
Detailed Description
Advantages of the application are further illustrated in the following description, taken in conjunction with the accompanying drawings and detailed description.
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present disclosure as detailed in the accompanying claims.
The terminology used in the present disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. As used in this disclosure 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 herein refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that although the terms first, second, third, etc. may be used in this disclosure to describe various information, these information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present disclosure. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
In the description of the present application, it should be understood that the numerical references before the steps do not identify the order in which the steps are performed, but are merely used to facilitate description of the present application and to distinguish between each step, and thus should not be construed as limiting the present application.
Fig. 1 schematically illustrates an architecture diagram of a live video stream acquisition system of a live video stream acquisition method according to an embodiment of the present application. In an exemplary embodiment, the live video streaming acquisition system may include a push terminal 100, an edge computing node 200, a user terminal 300, and an intranet server 400. The plug terminal 100 and the user terminal 300 may be a mobile phone, an iPAD, a tablet computer, etc. The edge computing node 200 and the intranet server 400 may be a server cluster or a cloud computing center formed by one server or multiple servers, which is not limited herein.
In this embodiment, the push terminal 100 is configured to push a live video stream that is live by a host user in a live broadcast room to the edge computing node 200.
The edge computing node 200 is a service node for receiving and storing live video streams pushed by the push terminal 100, and may have a plurality of service nodes.
The user terminal 300 is a terminal for a user to watch live video of a live user at a live room. The user terminal 300 may obtain a play address of a live video (triggered by a user in a live broadcasting room of a host user) in response to a play request of the live video, where the play address includes an intranet domain name and a source-returning identification field; performing domain name resolution on the intranet domain name in the play address to obtain an IP address of an intranet server; accessing the intranet server through the IP address, and sending the playing address to the intranet server; and receiving the live video stream returned by the intranet server.
The intranet server 400 is a server deployed in a lan, and is configured to parse the play address to obtain a source-returning identifier included in the source-returning identifier field, pull a direct-broadcast video stream to the edge computing node according to the source-returning identifier, and return the pulled direct-broadcast video stream to the user terminal 300.
Fig. 2 is a flow chart of a live video stream acquisition method according to an embodiment of the application. The live video stream acquisition method is applied to the user terminal, wherein the user terminal can be a personal computer, a mobile phone, a tablet and the like. It will be appreciated that the flow charts in the method embodiments are not intended to limit the order in which the steps are performed. As can be seen from the figure, the live video stream acquisition method provided in the embodiment includes:
step S20, responding to a playing request of the live video, and acquiring a playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field.
As an example, when a user participates in an on-line live broadcast training or an on-line live broadcast conference of an enterprise, the user can watch live videos of a live broadcast user in a live broadcast room by using a user terminal, so that the purpose that the user participates in the on-line live broadcast training or the on-line live broadcast conference of the enterprise is achieved. In this embodiment, after a user enters a live broadcast room of a host user, a live broadcast video playing request is triggered, and a user terminal responds to the live broadcast video playing request triggered by the user to obtain a playing address of a live broadcast video, so that a live broadcast video stream of the host user can be obtained according to the playing address, and decoding and playing are performed according to the obtained live broadcast video stream.
In order to avoid the problem that the user can directly obtain the IP address of the intranet server and thus potential safety hazards may be caused, in this embodiment, the play address of the live video exists in the form of the intranet domain name, so that even if the intranet domain name is leaked, the user of the wide area network cannot access the intranet server through the intranet domain name.
The intranet domain name refers to a domain name which can only be accessed and resolved in an enterprise intranet, that is, when a user accesses the intranet domain name through a wide area network, the intranet domain name cannot be accessed and resolved.
In this embodiment, the intranet refers to a Local Area Network (LAN) inside the enterprise. Wide area network refers to a Wide Area Network (WAN).
In this embodiment, each office location of the enterprise may have its own intranet domain name, which is used to point to the intranet server of the location, for example, office a has intranet domain name a; office B. There is an intranet domain name b.
The back source identifier field is a data field in which edge computing node the live video stream pushed by the push terminal is stored in the play address.
In this embodiment, the source identifier field is added in the play address instead of the IP address of the edge computing node, so that the user can be prevented from knowing which edge computing node is storing the live video stream, the live video stream is prevented from being watched by other users than the enterprise, and the security is improved.
In an exemplary embodiment, referring to fig. 3, the obtaining, in response to a play request of a live video, a play address of the live video may include:
step S30, responding to a play request of the live video, and acquiring a play address of the live video from a preset scheduling service request.
Specifically, the scheduling service is a service for distributing a play address of a live video to a user terminal, and the scheduling service may be deployed in a live server or may be deployed in another server, which is not limited in this embodiment.
Step S31, receiving the play address of the live video returned by the scheduling service according to the position information of the user terminal.
Specifically, the location information may be GPS information, LBS base station location information, or an IP address of a network to which the user terminal is connected, etc.
In this embodiment, the scheduling service may determine, according to the location information, where the user terminal is located, that is, whether the user terminal is a terminal used by a user in a place or a terminal used by a user in B place of the enterprise. Because the internal networks used by the office of the user in different places are different, after the dispatch service judges the position of the user terminal, the internal network domain name in the playing address can be determined according to the position, and then the playing address containing the determined internal network domain name is returned to the user terminal. For example, the employee at site A gives a playback address containing the intranet domain name at site A, and the employee at site B gives a playback address of the intranet domain name at site B.
In this embodiment, the scheduling service returns a play address including an intranet domain name corresponding to the location information according to the difference of the location information of the user terminal, so that users in each place can acquire live video streams to the intranet server by using respective intranets to watch live video, and compared with a mode that the existing intranet live architecture needs to watch in a cross-region manner, the problem that when watching in a cross-region manner, a VPN needs to be connected, and pushing is unstable and further the live quality is affected due to the fact that the VPN needs to be pushed is avoided.
And S21, performing domain name resolution on the intranet domain name in the play address to obtain the IP address of the intranet server.
Specifically, the user terminal may resolve the domain name in the play address into an IP address through a domain name resolution service. The domain name resolution service is a service for converting a domain name into IP. As an example, when the ***.com is accessed through the user terminal, the actual access server IP is first detected as 15.1.1.1 by the domain name resolution service, and then the user terminal performs the actual access through the IP address, in general, the mapping relationship between the domain name and the IP address is 1 to N, that is, one domain name may have multiple server IP addresses corresponding to each other.
The intranet server is a server deployed in the intranet.
In an exemplary embodiment, referring to fig. 4, the performing domain name resolution on the intranet domain name in the play address to obtain the IP address of the intranet server may include:
and step S40, acquiring IP addresses of a plurality of intranet servers corresponding to the intranet domain name.
Specifically, the IP addresses of the plurality of intranet servers mapped with the intranet domain name may be queried through the domain name resolution service, for example, 3 IP addresses mapped with the intranet domain name are obtained through query, which are respectively IP1, IP2 and IP3.
Step S41, selecting an IP address from the IP addresses of the intranet servers according to a preset selection rule as the IP address of the intranet server obtained by analysis.
Specifically, the selection rule is preset, and can be flexibly set and adjusted according to actual situations, for example, the selection rule is selected randomly, for example, the selection rule is used for performing redundancy allocation according to the equipment number of the user terminal, and the like.
In this embodiment, an IP address is selected from a plurality of IP addresses through a preset selection rule to be used as an IP address of an intranet server obtained by parsing, so that the intranet server for providing a live video stream for a user terminal is not fixed any more, and the intranet server can be deployed according to actual needs.
Step S22, accessing the intranet server through the IP address, sending the playing address to the intranet server, so that the intranet server can analyze the playing address to obtain a back source identifier contained in the back source identification field, and the intranet server can pull the live video stream to an edge computing node corresponding to the live video stream according to the back source identifier.
Specifically, after the user terminal analyzes the IP address of the intranet server, the user terminal may access the intranet server through the IP address, and may send the play address to the intranet server, so that the intranet server may obtain the live video stream according to the play address.
The edge computing node is a node for receiving and storing live video streams pushed by the push terminal in the existing live broadcast system. Since the anchor is distributed across the country, the edge computing nodes are also distributed across the country, and there are a very large number.
In an exemplary embodiment, referring to fig. 5, the parsing, by the intranet server, the play address to obtain a source-back identifier included in the source-back identifier field, and pulling, according to the source-back identifier, the live video stream to an edge computing node corresponding to the live video stream may include:
And S50, the intranet server extracts the source-returning identification field from the play address.
Specifically, when the intranet server obtains the play address, the source-returning identification field in the play address can be extracted, so that the source-returning identification field is extracted from the play address, and subsequent processing of the source-returning identification field is facilitated.
And step S51, the intranet server analyzes the source-returning identification field to obtain a source-returning identifier.
Specifically, the source-returning identification field contains an encrypted source-returning identifier, and the source-returning identifier is an identification for uniquely locating an edge node server for storing the live video stream.
In this embodiment, the security can be further improved by encrypting the source-return identifier. A step of
Step S52, the intranet server obtains the IP address of the edge computing node associated with the back source identifier according to the back source identifier.
Specifically, each back source identifier may be associated with an IP address of an edge computing node, so that the IP address of the edge computing node associated therewith may be found by the obtained back source identifier.
In an exemplary embodiment, referring to fig. 6, the obtaining, by the intranet server, the IP address of the edge computing node associated with the back source identifier according to the back source identifier may include:
in step S60, the intranet server obtains the IP address of the edge computing node associated with the echo identifier from a preset identifier obtaining service request.
Specifically, the identifier obtaining service is a service for detecting live video streams stored in each edge computing node in real time, and generating a mapping relationship between a source-returning identifier of each live video stream and an IP address of a corresponding edge computing node according to the detected live video streams. That is, the identifier acquisition service records which live video streams exist at each edge computing node, and generates a mapping relationship between the source identifier and the edge computing node for each live video stream. For example, the source-back identifier a of the live video stream a is associated with the IP address of the edge computing node a; the source-returning identifier B of the video live stream B is associated with the IP address of the edge computing node a; the back source identifier C of the live video stream C is associated with the IP address of the edge computing node B.
In this embodiment, the identifier obtaining service may be disposed in the intranet server, or may be disposed in another server, which is not limited in this embodiment.
Step S61, the intranet server receives the IP address of the edge computing node returned by the identifier obtaining service according to the source return identifier.
Specifically, after obtaining the echo source identifiers sent by the intranet server, the identifier computing service may query the mapping relationship between each echo source identifier and the IP address of the edge computing node, so as to find the IP address of the edge computing node corresponding to the echo source identifier. After the identifier computing service finds the IP address associated with the source-back identifier, the IP address is returned to the intranet server, so that the intranet server can perform source-back pulling to the edge computing node according to the IP address.
In this embodiment, the identifier is used to obtain the IP address of the service return edge computing node, so that the IP address of the edge computing node can be prevented from being revealed, and the security is improved.
And step S53, the intranet server accesses the edge computing node through the IP address and pulls the live video stream from the edge computing node.
Specifically, after obtaining the IP address of the edge computing node, the intranet server may access the edge computing node through the IP address, and pull the direct broadcast video stream from the edge computing node.
In this embodiment, the live video stream is obtained by performing source-back stream pulling on the edge computing node through the intranet server, so that the problem that the user in the intranet cannot view the live video stream in the manner that the user performs stream pulling and viewing from the CDN node after the live video stream is pushed to the CDN node through the edge computing node in the existing live video architecture can be solved.
Note that, the CDN node refers to a content delivery network node.
Step S23, receiving the live video stream returned by the intranet server.
Specifically, after the live video stream is pulled, the intranet server can return the live video stream to the user terminal, so that the user terminal can decode and play the pulled live video stream.
In this embodiment, the live video stream is preferably pushed to the edge computing node by the anchor user through the wide area network (also called the external network) using a push terminal.
According to the video stream acquisition method, the live video stream is acquired according to the intranet domain name and the source-back identification field, so that the live video stream can be directly pushed to the edge computing node, and the live video stream is acquired in a mode of pulling the source-back of the intranet server, thereby avoiding the intranet live server from being fixed, realizing flexible deployment of the intranet server, improving the stream bearing capacity and improving the safety.
In an exemplary embodiment, referring to fig. 7, after the step of accessing the intranet server through the IP address and sending the play address to the intranet server, the method further includes:
step S70, the intranet server judges whether the live video stream exists in a local memory.
Specifically, after the intranet server performs back source pulling to obtain the live video stream from the edge computing node for the first time, multiplexing of the live video stream can be achieved when the intranet server is accessed by other subsequent user terminals to obtain the live video stream, response time is reduced, the intranet server stores the live video stream into a local memory after the live video stream is obtained for the first time, and therefore when the intranet server is accessed by other subsequent users, the live video stream can be directly obtained from the intranet server without performing back source pulling operation to the edge computing node to obtain the live video stream. That is, after receiving the play address sent by the user terminal, the intranet server may first determine whether the live video stream exists in the local memory.
Step S71, if the live video stream exists in the local memory, the intranet server returns the live video stream;
Step S72, if the live video stream does not exist in the local memory, the intranet server parses the play address to obtain a source-back identifier included in the source-back identifier field, and pulls the live video stream to the corresponding edge computing node according to the source-back identifier.
Specifically, when a live video stream exists in the local memory, the intranet server can directly return the live video stream in the memory to the user terminal; when no live video stream exists in the local memory, the intranet server analyzes the play address to obtain a source-returning identifier contained in the source-returning identification field, and pulls the direct video stream to a corresponding edge computing node according to the source-returning identifier, so that the source-returning pulling direct video stream is realized.
The embodiment can reduce the response time by multiplexing the live video streams.
Referring to fig. 8, a block diagram of a live video streaming acquisition apparatus 80 according to an embodiment of the present application is shown.
In this embodiment, the live video streaming acquisition device 80 includes a series of computer program instructions stored in a memory, which when executed by a processor, can implement the live video streaming acquisition function of the embodiments of the present application. In some embodiments, based on the specific operations implemented by the portions of the computer program instructions, the live video streaming acquisition device 80 may be divided into one or more modules, which may be specifically divided as follows:
The response module 81 is configured to obtain a play address of a live video in response to a play request of the live video, where the play address includes an intranet domain name and a source-returning identification field;
the resolution module 82 is configured to perform domain name resolution on the intranet domain name in the play address, so as to obtain an IP address of the intranet server;
the access module 83 is configured to access the intranet server through the IP address, and send the play address to the intranet server, so that the intranet server analyzes the play address to obtain a back source identifier contained in the back source identifier field, and the intranet server pulls the live video stream to an edge computing node corresponding to the live video stream according to the back source identifier;
and the receiving module 84 is configured to receive the live video stream returned by the intranet server.
In an exemplary embodiment, the response module 81 is further configured to obtain, in response to a play request of a live video, a play address of the live video from a preset scheduling service request; and receiving the play address of the live video returned by the scheduling service according to the position information of the user terminal.
In an exemplary embodiment, the parsing module 82 is further configured to obtain IP addresses of a plurality of intranet servers corresponding to the intranet domain name; and selecting one IP address from the IP addresses of the intranet servers according to a preset selection rule as the IP address of the intranet server obtained by analysis.
In an exemplary embodiment, the intranet server resolving the play address to obtain a source-back identifier contained in the source-back identifier field, and pulling the direct-play video stream to the corresponding edge computing node according to the source-back identifier includes: the intranet server extracts the source-returning identification field from the play address; the intranet server analyzes the source-returning identification field to obtain a source-returning identifier; the intranet server acquires the IP address of the edge computing node associated with the back source identifier according to the back source identifier; and the intranet server accesses the edge computing node through the IP address and pulls the live video stream from the edge computing node.
In an exemplary embodiment, the intranet server obtaining, according to the source-back identifier, an IP address of an edge computing node associated with the source-back identifier includes: the intranet server acquires an IP address of an edge computing node associated with the source return identifier from a preset identifier acquisition service request; and the intranet server receives the IP address of the edge computing node returned by the identifier acquisition service according to the source return identifier.
In an exemplary embodiment, after the step of accessing the intranet server through the IP address and sending the play address to the intranet server, the method further includes: the intranet server judges whether the live video stream exists in a local memory or not; if the live video stream exists in the local memory, the intranet server returns the live video stream; if the live video stream does not exist in the local memory, the intranet server analyzes the play address to obtain a source-returning identifier contained in the source-returning identification field, and pulls the live video stream to a corresponding edge computing node according to the source-returning identifier.
In an exemplary embodiment, the live video stream is pushed to an edge computing node by a push terminal through a wide area network.
In an exemplary embodiment, the back source identifier is an identification for uniquely locating an edge node server for storing live video streams.
According to the video stream acquisition method, the live video stream is acquired according to the intranet domain name and the source-back identification field, so that the live video stream can be directly pushed to the edge computing node, and the live video stream is acquired in a mode of pulling the source-back stream of the intranet server, thereby avoiding the intranet live server from being fixed, realizing flexible deployment of the intranet server, improving the stream bearing capacity and improving the safety.
Fig. 9 schematically shows a hardware architecture diagram of a computer device 9 adapted to implement a live video stream acquisition method according to an embodiment of the application. In the present embodiment, the computer device 9 is a device capable of automatically performing numerical calculation and/or information processing in accordance with instructions set or stored in advance. For example, the server may be a tablet computer, a notebook computer, a desktop computer, a rack-mounted server, a blade server, a tower server, or a rack server (including a stand-alone server or a server cluster formed by a plurality of servers), etc. As shown in fig. 9, the computer device 9 includes at least, but is not limited to: memory 120, processor 121, and network interface 122 may be communicatively linked to each other by a system bus. Wherein:
the memory 120 includes at least one type of computer-readable storage medium, which may be volatile or nonvolatile, and specifically, includes flash memory, hard disk, multimedia card, card memory (e.g., SD or DX memory, etc.), random Access Memory (RAM), static Random Access Memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 120 may be an internal storage module of the computer device 9, such as a hard disk or a memory of the computer device 9. In other embodiments, the memory 120 may also be an external storage device of the computer device 9, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash Card (Flash Card) or the like, which are provided on the computer device 9. Of course, the memory 120 may also include both internal memory modules of the computer device 9 and external memory devices. In this embodiment, the memory 120 is generally used to store an operating system installed on the computer device 9 and various application software, such as program codes of a live video streaming acquisition method. In addition, the memory 120 may also be used to temporarily store various types of data that have been output or are to be output.
The processor 121 may be a central processing unit (Central Processing Unit, simply CPU), controller, microcontroller, microprocessor, or other live video stream acquisition chip in some embodiments. The processor 121 is typically used to control the overall operation of the computer device 9, such as performing control and processing related to data interaction or communication with the computer device 9, and the like. In this embodiment, the processor 121 is configured to execute program codes or process data stored in the memory 120.
The network interface 122 may comprise a wireless network interface or a wired network interface, which network interface 122 is typically used to establish a communication link between the computer device 9 and other computer devices. For example, the network interface 122 is used to connect the computer device 9 to an external terminal through a network, establish a data transmission channel and a communication link between the computer device 9 and the external terminal, and the like. The network may be a wireless or wired network such as an Intranet (Intranet), the Internet (Internet), a global system for mobile communications (Global System of Mobile communication, abbreviated as GSM), wideband code division multiple access (Wideband Code Division Multiple Access, abbreviated as WCDMA), a 4G network, a 5G network, bluetooth (Bluetooth), wi-Fi, etc.
It should be noted that fig. 9 only shows a computer device having components 120-122, but it should be understood that not all of the illustrated components are required to be implemented, and that more or fewer components may be implemented instead.
In this embodiment, the live video streaming acquisition method stored in the memory 120 may be divided into one or more program modules and executed by one or more processors (the processor 121 in this embodiment) to complete the present application.
The embodiment of the application provides a computer readable storage medium, and the computer readable storage medium stores a computer program thereon, and the computer program when executed by a processor realizes the steps of the live video stream acquisition method in the embodiment.
In this embodiment, the computer-readable storage medium includes a flash memory, a hard disk, a multimedia card, a card memory (e.g., SD or DX memory, etc.), a Random Access Memory (RAM), a Static Random Access Memory (SRAM), a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM), a programmable read-only memory (PROM), a magnetic memory, a magnetic disk, an optical disk, and the like. In some embodiments, the computer readable storage medium may be an internal storage unit of a computer device, such as a hard disk or a memory of the computer device. In other embodiments, the computer readable storage medium may also be an external storage device of a computer device, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash Card (Flash Card), etc. that are provided on the computer device. Of course, the computer-readable storage medium may also include both internal storage units of a computer device and external storage devices. In this embodiment, the computer readable storage medium is typically used to store an operating system and various application software installed on the computer device, for example, program codes of the live video stream acquisition method in the embodiment, and the like. Furthermore, the computer-readable storage medium may also be used to temporarily store various types of data that have been output or are to be output.
The apparatus embodiments described above are merely illustrative, wherein elements illustrated as separate elements may or may not be physically separate, and elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over at least two network elements. Some or all modules in the system can be screened out according to actual needs to realize the purpose of the scheme of the embodiment of the application. Those of ordinary skill in the art will understand and implement the present application without undue burden.
From the above description of embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus a general purpose hardware platform, or may be implemented by hardware. Those skilled in the art will appreciate that all or part of the processes implementing the methods of the above embodiments may be implemented by a computer program for instructing relevant hardware, where the program may be stored in a computer readable storage medium, and where the program may include processes implementing the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-only memory (ROM), a random access memory (RandomAccessMemory, RAM), or the like.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present application, and not for limiting the same; although the application has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some or all of the technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit of the application.

Claims (10)

1. The live video stream acquisition method is characterized by comprising the following steps of:
responding to a playing request of a live video, and acquiring a playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field;
performing domain name resolution on the intranet domain name in the play address to obtain an IP address of an intranet server;
accessing the intranet server through the IP address, and sending the play address to the intranet server, so that the intranet server can analyze the play address to obtain a back source identifier contained in the back source identification field, and the intranet server can pull the live video stream to an edge computing node corresponding to the live video stream according to the back source identifier, wherein the back source identifier is an identification for uniquely positioning the edge computing node for storing the live video stream;
Receiving the live video stream returned by the intranet server;
and performing domain name resolution on the intranet domain name in the play address to obtain an IP address of the intranet server, wherein the obtaining comprises the following steps:
acquiring IP addresses of a plurality of intranet servers corresponding to the intranet domain name;
and selecting one IP address from the IP addresses of the intranet servers according to a preset selection rule as the IP address of the intranet server obtained by analysis.
2. The method for acquiring a live video stream according to claim 1, wherein the acquiring, in response to a play request of a live video, a play address of the live video includes:
responding to a play request of a live video, and acquiring a play address of the live video from a preset scheduling service request;
and receiving the play address of the live video returned by the scheduling service according to the position information of the user terminal.
3. The method of claim 1, wherein the parsing, by the intranet server, the play address to obtain a source-back identifier included in the source-back identifier field, and pulling the live video stream to an edge computing node corresponding to the live video stream according to the source-back identifier includes:
The intranet server extracts the source-returning identification field from the play address;
the intranet server analyzes the source-returning identification field to obtain a source-returning identifier;
the intranet server acquires the IP address of the edge computing node associated with the back source identifier according to the back source identifier;
and the intranet server accesses the edge computing node through the IP address and pulls the live video stream from the edge computing node.
4. A live video streaming acquisition method according to claim 3, wherein the intranet server acquiring the IP address of the edge computing node associated with the back source identifier according to the back source identifier comprises:
the intranet server acquires the IP address of the edge computing node associated with the back source identifier from a preset identifier acquisition service request, wherein the identifier acquisition service is a service for detecting live video streams stored in each edge computing node in real time and generating the mapping relation between the back source identifier of each live video stream and the IP address of the corresponding edge computing node according to the detected live video streams;
And the intranet server receives the IP address of the edge computing node returned by the identifier acquisition service according to the source return identifier.
5. The method for obtaining a live video stream according to any one of claims 1 to 4, wherein after the step of accessing the intranet server through the IP address and sending the play address to the intranet server, further comprises:
the intranet server judges whether the live video stream exists in a local memory or not;
if the live video stream exists in the local memory, the intranet server returns the live video stream;
if the live video stream does not exist in the local memory, the intranet server analyzes the play address to obtain a source-returning identifier contained in the source-returning identification field, and pulls the live video stream to a corresponding edge computing node according to the source-returning identifier.
6. The method according to any one of claims 1 to 4, wherein the live video stream is pushed to an edge computing node by a push terminal through a wide area network.
7. A live video stream acquisition device, comprising:
The response module is used for responding to the playing request of the live video and obtaining the playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field;
the resolution module is used for carrying out domain name resolution on the intranet domain name in the play address to obtain the IP address of the intranet server;
the access module is used for accessing the intranet server through the IP address, sending the playing address to the intranet server, analyzing the playing address by the intranet server to obtain a back source identifier contained in the back source identification field, and pulling the live video stream to an edge computing node corresponding to the live video stream by the intranet server according to the back source identifier, wherein the back source identifier is an identification for uniquely positioning the edge computing node for storing the live video stream;
the receiving module is used for receiving the live video stream returned by the intranet server;
the analysis module is further used for acquiring IP addresses of a plurality of intranet servers corresponding to the intranet domain name; and selecting one IP address from the IP addresses of the intranet servers according to a preset selection rule as the IP address of the intranet server obtained by analysis.
8. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method of any one of claims 1 to 7 when the computer program is executed.
9. A live video stream acquisition system, comprising:
the push terminal is used for pushing the live video stream to the edge computing node;
the edge computing node is used for storing the live video stream;
the user terminal is used for responding to a playing request of the live video and obtaining a playing address of the live video, wherein the playing address comprises an intranet domain name and a source returning identification field; performing domain name resolution on the intranet domain name in the play address to obtain an IP address of an intranet server; accessing the intranet server through the IP address, and sending the playing address to the intranet server; receiving a live video stream returned by the intranet server; and performing domain name resolution on the intranet domain name in the play address to obtain an IP address of the intranet server, wherein the obtaining comprises the following steps: acquiring IP addresses of a plurality of intranet servers corresponding to the intranet domain name; selecting an IP address from the IP addresses of the intranet servers according to a preset selection rule as the IP address of the intranet server obtained by analysis;
The intranet server is configured to parse the play address to obtain a source return identifier contained in the source return identifier field, pull a direct-broadcast video stream to the edge computing node according to the source return identifier, and return the pulled direct-broadcast video stream to the user terminal, where the source return identifier is an identifier for uniquely locating the edge computing node for storing the direct-broadcast video stream.
10. A computer-readable storage medium having stored thereon a computer program, characterized by: the computer program implementing the steps of the method of any of claims 1 to 7 when executed by a processor.
CN202111543820.1A 2021-12-16 2021-12-16 Live video stream acquisition method and device Active CN114245182B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111543820.1A CN114245182B (en) 2021-12-16 2021-12-16 Live video stream acquisition method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111543820.1A CN114245182B (en) 2021-12-16 2021-12-16 Live video stream acquisition method and device

Publications (2)

Publication Number Publication Date
CN114245182A CN114245182A (en) 2022-03-25
CN114245182B true CN114245182B (en) 2023-11-21

Family

ID=80757340

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111543820.1A Active CN114245182B (en) 2021-12-16 2021-12-16 Live video stream acquisition method and device

Country Status (1)

Country Link
CN (1) CN114245182B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115529472B (en) * 2022-11-28 2023-03-31 广州市千钧网络科技有限公司 Playing area limiting method and device, electronic equipment and storage medium
CN116996481B (en) * 2023-09-27 2024-02-23 联通在线信息科技有限公司 Live broadcast data acquisition method and device, electronic equipment and storage medium

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108540816A (en) * 2018-03-28 2018-09-14 腾讯科技(深圳)有限公司 A kind of live video acquisition methods, device and storage medium
CN108737405A (en) * 2018-05-10 2018-11-02 网宿科技股份有限公司 A kind of method, CCL servers and system carrying out water conservancy diversion to live video stream
CN110012300A (en) * 2018-01-04 2019-07-12 华为技术有限公司 Net cast method and device
CN110913270A (en) * 2018-09-14 2020-03-24 北京微播视界科技有限公司 Live broadcasting method and device
CN111263171A (en) * 2020-02-25 2020-06-09 北京达佳互联信息技术有限公司 Live streaming media data acquisition method and edge node area networking system
CN111464759A (en) * 2020-03-26 2020-07-28 广州虎牙科技有限公司 Live broadcast directing method, device, storage medium and equipment
CN113037869A (en) * 2021-04-14 2021-06-25 北京百度网讯科技有限公司 Method and apparatus for back-sourcing of content distribution network system
CN113660538A (en) * 2021-08-11 2021-11-16 上海哔哩哔哩科技有限公司 Live broadcast plug flow source returning method and system

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110012300A (en) * 2018-01-04 2019-07-12 华为技术有限公司 Net cast method and device
CN108540816A (en) * 2018-03-28 2018-09-14 腾讯科技(深圳)有限公司 A kind of live video acquisition methods, device and storage medium
CN108737405A (en) * 2018-05-10 2018-11-02 网宿科技股份有限公司 A kind of method, CCL servers and system carrying out water conservancy diversion to live video stream
CN110913270A (en) * 2018-09-14 2020-03-24 北京微播视界科技有限公司 Live broadcasting method and device
CN111263171A (en) * 2020-02-25 2020-06-09 北京达佳互联信息技术有限公司 Live streaming media data acquisition method and edge node area networking system
CN111464759A (en) * 2020-03-26 2020-07-28 广州虎牙科技有限公司 Live broadcast directing method, device, storage medium and equipment
CN113037869A (en) * 2021-04-14 2021-06-25 北京百度网讯科技有限公司 Method and apparatus for back-sourcing of content distribution network system
CN113660538A (en) * 2021-08-11 2021-11-16 上海哔哩哔哩科技有限公司 Live broadcast plug flow source returning method and system

Also Published As

Publication number Publication date
CN114245182A (en) 2022-03-25

Similar Documents

Publication Publication Date Title
CN114245182B (en) Live video stream acquisition method and device
US8069224B2 (en) Method, equipment and system for resource acquisition
US20170155940A1 (en) Method For Providing Video Service, Method For Access Authentication, Electronic Device And Non-Transitory Computer-Readable Storage Medium
US10812314B2 (en) Methods and apparatuses for pushing a message
US10225231B2 (en) Method and server of remote information query
US10516856B2 (en) Network video recorder cluster and method of operation
CN104410546A (en) Testing method and device of real-time processing system
CN105391979B (en) A kind of method and apparatus of business processing
WO2018145538A1 (en) Message processing method and device for live broadcast platform
US11201928B2 (en) Method of referencing a connection session with a wireless communication device in a local area, a system for implementing this method, a method of referencing an application user, a machine-readable medium for implementing this method, as well as a method of collecting data on the wireless communication device user, and a machine-readable medium for implementing this method
US20210105195A1 (en) Method for measuring end-to-end internet application performance
US10374933B2 (en) Systems and methods for monitoring operational statuses of network services
CN111431818A (en) Cross-domain request traffic distribution method and device, storage medium and computer equipment
EP3579526B1 (en) Resource file feedback method and apparatus
CN110231965B (en) Cloud device, application processing method and electronic device
KR20190021848A (en) Method for monitoring server, apparatus and system for executing the method
CN111049710A (en) Method and device for accessing server
JP2005050267A (en) Content distribution system, content distribution method, and content distribution program
CN111159744A (en) Method, device, equipment and storage medium for determining source user of data report
CN108810043B (en) Method and device for storing comment information
US9323857B2 (en) System and method for providing content-related information based on digital watermark and fingerprint
US11558430B2 (en) Information collection system, information collection method, and non-transitory computer readable medium storing control program
CN111277615B (en) User behavior tracking method based on browser, terminal device and server
CN113641972A (en) Account identification method and device, electronic equipment and storage medium
KR102032460B1 (en) Apparatus and method for video realtime transcoding in individual cloud environment

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