CN110213330B - Pre-push system, method, device, electronic equipment and computer readable medium - Google Patents

Pre-push system, method, device, electronic equipment and computer readable medium Download PDF

Info

Publication number
CN110213330B
CN110213330B CN201910351574.6A CN201910351574A CN110213330B CN 110213330 B CN110213330 B CN 110213330B CN 201910351574 A CN201910351574 A CN 201910351574A CN 110213330 B CN110213330 B CN 110213330B
Authority
CN
China
Prior art keywords
push
target
server
live stream
node
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
CN201910351574.6A
Other languages
Chinese (zh)
Other versions
CN110213330A (en
Inventor
殷松松
周志伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN201910351574.6A priority Critical patent/CN110213330B/en
Publication of CN110213330A publication Critical patent/CN110213330A/en
Application granted granted Critical
Publication of CN110213330B publication Critical patent/CN110213330B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • 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

Abstract

The embodiment of the application discloses a pre-pushing system, a pre-pushing method, a pre-pushing device, electronic equipment and a computer readable medium. An embodiment of the system comprises: each pre-push node device of the peer-to-peer network system sends a pre-push task request containing local information to the pre-push server; the pre-push server determines target pre-push node equipment in the pre-push node equipment based on the received local information, and sends a pre-push task to the target pre-push node equipment; and the target pre-push node equipment downloads a target live stream indicated by the pre-push task and uploads the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system. This embodiment relieves server stress.

Description

Pre-push system, method, device, electronic equipment and computer readable medium
Technical Field
The embodiment of the application relates to the technical field of computers, in particular to a pre-pushing system, a pre-pushing method, a pre-pushing device, electronic equipment and a computer readable medium.
Background
In the peak time period of the live broadcast, the access amount of a Content Delivery Network (CDN) server is large. Because the bandwidth of the CDN server is limited and the user has an increasingly high requirement for the definition of the live view, situations often occur in which the data download delay is long and the live view is stuttered.
In the existing method, a Peer-to-Peer (P2P) network is generally constructed by using a Personal Computer (PC) used by a user, and when the user watches a live broadcast through a live broadcast client installed in the PC, the PC is used to upload a live broadcast stream corresponding to the live broadcast (i.e. stream media data received during the live broadcast) to other PC devices in the P2P, so as to relieve the pressure of a server. However, as the number of users using PCs decreases, uploading data provided only by the PCs cannot meet the user's needs, so that the stress on the server cannot be effectively relieved.
Disclosure of Invention
The embodiment of the application provides a pre-push system, a pre-push method, a pre-push device, electronic equipment and a computer readable medium, so as to solve the technical problem that in the prior art, the pressure of a server cannot be effectively relieved due to the fact that data are uploaded only through a PC.
In a first aspect, an embodiment of the present application provides a pre-push system, including a peer-to-peer network system and a pre-push server, where the peer-to-peer network system includes a plurality of node devices, and the plurality of node devices includes one or more pre-push node devices; each pre-push node device is configured to send a pre-push task request containing local information to a pre-push server; a pre-push server configured to determine a target pre-push node device of the one or more pre-push node devices based on the received local information and send a pre-push task to the target pre-push node device; and the target pre-push node equipment is configured to download the target live stream indicated by the pre-push task and upload the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system.
In some embodiments, each pre-push node device is further configured to send first query information to the pre-push server, where the first query information is used to query whether to initiate a pre-push operation; receiving first response information returned by a pre-push server; and in response to the fact that the first response information indicates that the pre-pushing operation is not started, retransmitting the first inquiry information to the pre-pushing server at intervals of a first preset duration.
In some embodiments, the pre-push server is further configured to: inquiring the number of users watching each live stream currently; determining a target live stream to be pushed in advance based on the number of users; and sending a pre-pushing task for indicating pre-pushing of the target live stream to the target pre-pushing node equipment.
In some embodiments, the system further comprises a data server; and a target pre-push node device further configured to: in the process of downloading and uploading the target live stream, counting the pre-pushing condition every second preset time length, and sending a statistical result to the data server, wherein the statistical result comprises information for describing the downloading condition and information for describing the uploading condition.
In some embodiments, the pre-push task further includes configuration information, and the configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some embodiments, the target pre-push node device is further configured to: sending second inquiry information to the pre-push server based on the waiting time length; and a pre-push server further configured to determine whether the target live stream needs to be updated; if so, updating the pre-push task, and returning second response information containing the updated pre-push task to the target pre-push node equipment; if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node equipment.
In some embodiments, the peer-to-peer network system further includes a content delivery network CDN server, each node device in the peer-to-peer network system is in communication connection with the CDN server, and a delay waiting duration when each pre-push node device requests a live stream from the CDN server is smaller than a delay waiting duration when another node device requests a live stream from the CDN server, where the another node device is a node device in the peer-to-peer network system except the pre-push node device.
In some embodiments, the peer-to-peer network system further includes a transmission control protocol TCP server, each pre-push node device is in communication connection with the TCP server in a long connection manner, and the other node devices are not in communication connection with the TCP server; and the TCP server is configured to respond to the received live stream acquisition request sent by the pre-push node equipment and return the live stream indicated by the live stream acquisition request to the pre-push node equipment sending the live stream acquisition request.
In a second aspect, an embodiment of the present application provides a pre-push method, applied to a pre-push node device in a peer-to-peer network system, including: sending a pre-push task request containing local information to a pre-push server; and in response to receiving the pre-push task returned by the pre-push server, downloading the target live stream indicated by the pre-push task, and uploading the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system.
In some embodiments, before sending the pre-push task request including the local information to the pre-push server, the method further comprises: sending first inquiry information to a pre-push server, wherein the first inquiry information is used for inquiring whether to start a pre-push operation; receiving response information returned by the pre-push server; and in response to the fact that the response information indicates that the pre-push operation is not started, retransmitting the first inquiry information to the pre-push server at intervals of a first preset duration.
In some embodiments, the method further comprises: in the process of downloading and uploading the target live stream, counting the pre-pushing condition every second preset time length, and sending a statistical result to the data server, wherein the statistical result comprises information for describing the downloading condition and information for describing the uploading condition.
In some embodiments, the pre-push task further includes configuration information, and the configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some embodiments, after responding to receiving the pre-push task returned by the pre-push server, the method further comprises: sending second inquiry information to the pre-push server based on the waiting time length; and receiving second response information containing the updated pre-push task or third response information used for indicating that the pre-push task does not need to be updated.
In a third aspect, an embodiment of the present application provides a pre-push apparatus, which is applied to a pre-push node device in a peer-to-peer network system, and includes: a first sending unit configured to send a pre-push task request containing local information to a pre-push server; the first receiving unit is configured to respond to the receiving of the pre-push task returned by the pre-push server, download the target live stream indicated by the pre-push task, and upload the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system.
In some embodiments, the apparatus further comprises: the second sending unit is configured to send first inquiry information to the pre-push server, wherein the first inquiry information is used for inquiring whether to start a pre-push operation; the second receiving unit is configured to receive response information returned by the pre-push server; and the third sending unit is configured to respond to the fact that the response information indicates that the pre-pushing operation is not started, and resend the first inquiry information to the pre-pushing server at intervals of a first preset time length.
In some embodiments, the apparatus further comprises: and the fourth sending unit is configured to count the pre-pushing condition every second preset time length in the process of downloading and uploading the target live stream, and send a statistical result to the data server, wherein the statistical result comprises information for describing the downloading condition and information for describing the uploading condition.
In some embodiments, the pre-push task further includes configuration information, and the configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some embodiments, the apparatus further comprises: a fifth sending unit configured to send the second query information to the pre-push server based on the waiting duration; a third receiving unit configured to receive second response information including the updated pre-push task or third response information indicating that the pre-push task does not need to be updated.
In a fourth aspect, an embodiment of the present application provides a pre-push method, applied to a pre-push server, including: receiving pre-push task requests sent by each pre-push node device in a peer-to-peer network system, wherein the pre-push task requests comprise local information; and determining a target pre-push node device in the one or more pre-push node devices based on the received local information, sending a pre-push task to the target pre-push node device so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and uploading the target live stream to a node device requesting the target live stream in the peer-to-peer network system.
In some embodiments, before receiving that each pre-push node device in the peer-to-peer network system sends a pre-push task request, the method further includes: receiving first inquiry information sent by each pre-push node device, wherein the first inquiry information is used for inquiring whether a pre-push function is started or not; and returning first response information to each pre-push server, wherein the first response information is used for indicating whether response information of a pre-push function is started or not.
In some embodiments, sending the pre-push task to the target pre-push node device includes: inquiring the number of users currently watching each live stream; determining a target live stream to be pushed in advance based on the number of users; and sending a pre-pushing task for indicating pre-pushing of the target live stream to the target pre-pushing node equipment.
In some embodiments, the pre-push task further includes configuration information, and the configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some embodiments, after sending the pre-push task to the target pre-push node device, the method further comprises: receiving second inquiry information sent by the target pre-push node equipment; judging whether the target live stream needs to be updated or not; if yes, updating the pre-push task, and returning second response information containing the updated pre-push task to the target pre-push node equipment; if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node equipment.
In a fifth aspect, an embodiment of the present application provides a pre-push device, which is disposed in a pre-push server, and includes: the first receiving unit is configured to receive a pre-push task request sent by each pre-push node device in a peer-to-peer network system, wherein the pre-push task request contains local information; the first sending unit is configured to determine a target pre-push node device of the one or more pre-push node devices based on the received local information, send a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and upload the target live stream to a node device requesting the target live stream in the peer-to-peer network system.
In some embodiments, the apparatus further comprises: the second receiving unit is configured to receive first query information sent by each pre-push node device, wherein the first query information is used for querying whether a pre-push function is started or not; and the second sending unit is configured to return first response information to each pre-push server, wherein the first response information is used for indicating whether response information of a pre-push function is started or not.
In some embodiments, the first sending unit comprises: a query module configured to query the number of users currently watching each live stream; a determination module configured to determine a pre-pushed target live stream based on the number of users; the sending module is configured to send a pre-push task for indicating a pre-push target live stream to the target pre-push node device.
In some embodiments, the pre-push task further includes configuration information, and the configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some embodiments, the apparatus further comprises: a third receiving unit, configured to receive second query information sent by the target pre-push node device; the determining unit is configured to determine whether the target live stream needs to be updated; the third sending unit is configured to update the pre-push task and return second response information containing the updated pre-push task to the target pre-push node device if the pre-push task is updated; and if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node device.
In a sixth aspect, an embodiment of the present application provides a pre-push method, including: each pre-push node device in the peer-to-peer network system sends a pre-push task request containing local information to a pre-push server; the pre-push server determines a target pre-push node device in one or more pre-push node devices based on the received local information, and sends a pre-push task to the target pre-push node device; and the target pre-push node equipment downloads the target live stream indicated by the pre-push task and uploads the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system.
In a seventh aspect, an embodiment of the present application provides an electronic device, including: one or more processors; a storage device having one or more programs stored thereon, which when executed by one or more processors, cause the one or more processors to implement the method of any of the embodiments of the second and fourth aspects as described above.
In an eighth aspect, the present application provides a computer-readable medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the method according to any one of the second and fourth aspects.
The pre-push system, method and device provided by the embodiment of the application comprise the steps that firstly, pre-push node equipment in a peer-to-peer network system sends a pre-push task request containing local information to a pre-push server; then the pre-push server determines target pre-push node equipment based on the local information of each pre-push node equipment and sends a pre-push task to the target pre-push node equipment; and finally, downloading the target live stream indicated by the pre-push task by the target pre-push node equipment, and uploading the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system. Therefore, the target live broadcast stream can be pushed to the target pre-push node equipment in advance by setting the pre-push node equipment in the peer-to-peer network system and selecting the target pre-push node equipment in the pre-push node equipment to execute the pre-push task. Since the target pre-push node device also has the resource of the target live stream, when other node devices of the peer-to-peer network request the target live stream, the target live stream can be downloaded from the target pre-push node device. The server storing the target live stream and the target pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be effectively relieved.
Drawings
Other features, objects and advantages of the present application will become more apparent upon reading of the following detailed description of non-limiting embodiments thereof, made with reference to the accompanying drawings in which:
FIG. 1 is a timing diagram of one embodiment of a pre-push system according to the present application;
FIG. 2 is a timing diagram of yet another embodiment of a pre-push system according to the present application;
FIG. 3 is a schematic diagram of a structure of a pre-push system according to the present application;
FIG. 4 is a flow diagram of one embodiment of a pre-push method according to the present application;
FIG. 5 is a schematic diagram of an embodiment of a pre-push apparatus according to the present application;
FIG. 6 is a flow diagram of one embodiment of a pre-push method according to the present application;
FIG. 7 is a schematic diagram of an embodiment of a pre-push apparatus according to the present application;
FIG. 8 is a flow diagram of one embodiment of a pre-push method according to the present application;
FIG. 9 is a block diagram of a computer system suitable for use in implementing the electronic device of an embodiment of the present application.
Detailed Description
The present application will be described in further detail with reference to the following drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not to be construed as limiting the invention. It should be noted that, for convenience of description, only the portions related to the present invention are shown in the drawings.
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
Referring to fig. 1, a timing diagram of one embodiment of a pre-push system according to the present application is shown.
The pre-push system comprises a Peer-to-Peer (Peer-to-Peer, P2P) system and a pre-push server. The peer-to-peer network system includes a plurality of node devices. In practice, a Peer-to-Peer network, i.e., a Peer-to-Peer computer network, is a distributed application architecture that distributes tasks and workloads among peers (peers). The peer is a node device of the peer-to-peer network.
Here, the node device may be various electronic devices installed with a live client, which may include, but is not limited to, a smart phone, a tablet computer, a laptop computer, and the like.
Here, the plurality of node devices in the peer-to-peer network may include one or more pre-push node devices. The pre-push node device may be a node device that starts a pre-push function in a live broadcast client. The pre-push node equipment can execute a pre-push task sent by the pre-push server. That is, the target live stream indicated by the pre-push task can be downloaded in advance, so that other node devices in the peer-to-peer network system request the target live stream to provide the uploaded data of the target live stream.
As shown in fig. 1, the timing diagram of one embodiment of the pre-push system may involve the following steps:
step 101, each pre-push node device sends a pre-push task request containing local information to a pre-push server.
In this embodiment, each pre-push node device of the peer-to-peer network may send a pre-push task request including local information to the pre-push server. The local information may include, but is not limited to, a local upload bandwidth, an operator of a network used by the pre-push node device, a version of a live broadcast client installed in the pre-push node device, information indicating whether there is a live broadcast stream currently being downloaded, a reason for closing the pre-push operation last time, and the like.
Step 102, the pre-push server determines a target pre-push node device in the pre-push node devices based on the received local information.
In this embodiment, the pre-push server may determine a target pre-push node device in the pre-push node devices based on the received local information of each pre-push node device. In practice, the pre-push server may determine the target pre-push node device based on various rules set in advance. The number of target pre-push node devices may be one or more.
As an example, since the local information may include information indicating whether there is a currently downloaded live stream, the pre-push server may select, based on the information, a pre-push node device that does not currently download the live stream as the target pre-push node device.
As another example, since the local information may include a reason for closing the pre-push operation last time, the pre-push server may analyze the pre-push quality of each pre-push node device based on the reason for closing the pre-push operation last time by each pre-push node device, and then select a pre-push node device with higher pre-push quality as the target pre-push node device.
It should be noted that, the pre-push server may also determine the target pre-push node device by combining multiple factors, which is not limited herein. For example, in the process of determining the target pre-push node device, the proportion of the target pre-push node devices using networks of different operators may be controlled according to the operator information. In addition, in the process of determining the target pre-push node device, the proportion of the target pre-push node device using the live client of the latest version is controlled according to the version of the live client installed in the pre-push node device.
Step 103, the pre-push server sends a pre-push task to the target pre-push node device.
In this embodiment, the pre-push server may first select a pre-pushed target live stream, and then send a pre-push task to the target pre-push node device, where the pre-push task may be used to instruct the target pre-push node device to download the target live stream. In practice, the pre-push task may include information such as an identifier or a name of the target live stream, so that the target pre-push node device downloads the target live stream.
It should be noted that the pre-push server may select the target live stream in various ways. As an example, the number of users currently watching each live stream may be queried, and the live stream with the number of users greater than a preset threshold may be used as the target live stream. As another example, the bandwidth pressure of each server providing the live stream download may be queried, and the live stream provided by the server with the highest bandwidth pressure is taken as the target live stream.
In some optional implementations of this embodiment, the pre-push task may further include configuration information. The configuration information may include various configuration parameters. For example, the specified data amount of the target video stream uploaded by the target pre-push node and the waiting time for the target pre-push node to send the second query information may be included. The second query information is used to query whether the pre-push task needs to be updated.
In some optional implementations of this embodiment, the pre-push server may query the number of users currently watching each live stream. Then, a pre-pushed target live stream may be determined based on the number of users. For example, the live stream with the number of users greater than a preset threshold is taken as the target live stream. And finally, a pre-push task for indicating pre-pushing of the target live stream can be sent to the target pre-push node device.
And 104, downloading the target live stream indicated by the pre-pushing task by the target pre-pushing node equipment, and uploading the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system.
In this embodiment, after the target pre-push node device receives the pre-push task, a target live stream indicated by the pre-push task may be determined. Accordingly, the target live stream can be downloaded from a server storing the target live stream.
In the process of downloading the target live stream and after the target live stream is finished, the target pre-push node equipment can upload the downloaded target live stream to node equipment requesting the target live stream in a peer-to-peer network system, so that pressure is shared for a server.
According to the system provided by the embodiment of the application, the target live broadcast stream can be pushed to the target pre-push node equipment in advance by setting the pre-push node equipment in the peer-to-peer network system and selecting the target pre-push node equipment in the pre-push node equipment to execute the pre-push task. Since the target pre-push node device also has the resources of the target live stream, when other node devices of the peer-to-peer network request the target live stream, the target live stream can be downloaded from the target pre-push node device. The server storing the target live stream and the target pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be effectively relieved.
Referring to fig. 2, a timing diagram of one embodiment of a pre-push system according to the present application is shown. In this embodiment, the structure of the pre-push system can be seen in fig. 3. As shown in fig. 3, the pre-push system includes a peer-to-peer network system and a pre-push server. The peer-to-peer network system includes a plurality of node devices, where the plurality of node devices include one or more pre-push node devices, and node devices other than the pre-push node devices may be referred to as other node devices. As shown in fig. 3, the peer-to-peer Network system may further include a CDN (Content Delivery Network) server, and each node device may be communicatively connected to the CDN server, so that a live stream may be downloaded from the CDN server. It should be noted that each arrow in fig. 3 may indicate a data transmission direction. As shown in fig. 3, the arrow pointing from the CDN server to the pre-push node device and other node devices in fig. 3 may indicate that the CDN server can send data (e.g., live streaming) to the pre-push node device and other node devices.
It should be noted that, when a node device in the peer-to-peer network system requests data in the CDN server, a delay time is usually required. Therefore, the time length of the delayed time period may be used as the delay waiting time length, and the delay waiting time length of the pre-push node device and the delay waiting time lengths of the other node devices may be set in advance. The node devices in the peer-to-peer network system except the pre-push node device.
When the delay waiting time of different node devices is set, the delay waiting time when each pre-push node device requests the live stream from the CDN server may be shorter than the delay waiting time when other node devices request the live stream from the CDN server. For example, the delay latency of the pre-push node device may be 10 seconds less than the delay latency of the other node devices. Therefore, when the pre-push node equipment acquires the live stream, the pre-push node equipment is advantageous in time, so that the uploading bandwidth of the pre-push node equipment is favorably and fully utilized to output data for the peer-to-peer network, and the pressure of the server is reduced.
It should be noted that, as shown in fig. 3, a TCP (Transmission Control Protocol) server may be further included in the peer-to-peer network system. Here, each pre-push node device may be communicatively connected to the TCP server in a long connection manner. The TCP server responds to the received live stream acquisition request sent by the pre-push node equipment, and can return the live stream indicated by the live stream acquisition request to the pre-push node equipment sending the live stream acquisition request. Through the long connection mode communication connection, connection reestablishment when the live stream is requested each time can be avoided, and the efficiency of pre-pushing node equipment for obtaining the live stream is improved. In addition, other node devices in the peer-to-peer network system are not communicatively connected to the TCP server. Therefore, the TCP server only provides the live stream resources for the pre-push node equipment, and the advantage that the pre-push node equipment acquires the live stream is further ensured. Therefore, other node devices can only download the live stream from the pre-push node device or the CDN server.
As shown in fig. 2, a timing diagram of an embodiment of the pre-push system may involve the following steps:
step 201, each pre-push node device sends first query information to a pre-push server.
In this embodiment, when each pre-push node device detects that the installed live client is started, it may send first query information to the pre-push server. The first query message may be used to query whether to start a pre-push operation.
Step 202, the pre-push server returns the first response information to the pre-push node device.
In this embodiment, in response to determining that the first response information indicates that the pre-push operation is not started, the pre-push node device retransmits the first query information to the pre-push server at an interval of a first preset duration. Step 203 may be performed in response to determining that the first reply information indicates that a pre-push operation is initiated.
In step 203, each pre-push node device sends a pre-push task request including local information to the pre-push server.
Step 204, the pre-push server determines a target pre-push node device in the pre-push node devices based on the received local information.
It should be noted that the operations in steps 203-204 are substantially the same as the operations in steps 101-102, and are not described here again.
Step 205, the pre-push server sends a pre-push task to the target pre-push node device.
In this embodiment, the pre-push server queries the number of users currently watching each live stream. Then, a pre-pushed target live stream may be determined based on the number of users. For example, the target live stream is the stream having the number of users greater than a preset threshold. And finally, a pre-push task for indicating pre-pushing of the target live stream can be sent to the target pre-push node device.
It should be noted that the pre-push task may further include configuration information. The configuration information may include various configuration parameters. For example, the specified data amount of the target video stream uploaded by the target pre-push node and the waiting time for the target pre-push node to send the second query message may be included. The second query message is used to query whether the pre-push task needs to be updated.
And step 206, downloading the target live stream indicated by the pre-push task by the target pre-push node device, and uploading the target live stream to the node device requesting the target live stream in the peer-to-peer network system.
In this embodiment, after the target pre-push node device receives the pre-push task, a target live stream indicated by the pre-push task may be determined. Accordingly, the target live stream can be downloaded from a server in which the target live stream is stored.
In the process of downloading the target live stream and after the target live stream is finished, the target pre-push node equipment can upload the downloaded target live stream to node equipment requesting the target live stream in a peer-to-peer network system. Thus, the stress is shared for the servers.
In this embodiment, in the process of downloading and uploading the target live stream, the target pre-push node device may count the pre-push condition every second preset time (for example, 5 minutes), and send the statistical result to the data server. The statistical result may include information describing a downloading situation (e.g., a downloaded data amount, a downloading time, etc.) and information describing an uploading situation (e.g., an uploaded data amount, an uploading time, etc.). Therefore, data support can be provided for subsequent data analysis. In practice, the target pre-push node device may perform statistics on push conditions by using a live client installed on the target pre-push node device.
And step 207, the target pre-push node device sends the second query information to the pre-push server based on the waiting duration.
In this embodiment, since the pre-push task may further include configuration information, the configuration parameter in the configuration information may include a waiting time for the target pre-push node to send the second query information. Therefore, the target pre-push node device may start timing when receiving the pre-push task, and send the second query message to the pre-push server when the timed time reaches the waiting time.
And step 208, the pre-push server judges whether the target live stream needs to be updated.
In this embodiment, after receiving the second query information, the pre-push server may count the number of users currently watching each live stream again. Then, based on the number of users, determining the live stream with the number of users greater than a preset threshold. And comparing the currently determined live stream with the target live stream to determine whether the target live stream needs to be updated. And if the currently determined live stream is consistent with the target live stream, the target live stream does not need to be updated. And if the currently determined live stream is inconsistent with the target live stream, updating the target live stream.
And 209, in response to determining that the target live stream needs to be updated, the pre-push server updates the pre-push task and returns second response information containing the updated pre-push task to the target pre-push node device, and in response to determining that the target live stream does not need to be updated, the pre-push server returns third response information indicating that the pre-push task does not need to be updated to the target pre-push node device.
On one hand, the pre-push system provided by the embodiment of the application can pre-push the target live stream to the target pre-push node device by setting the pre-push node device in the peer-to-peer network system and selecting the target pre-push node device in the pre-push node device to execute the pre-push task. Therefore, when other node devices of the peer-to-peer network request the target live stream, the target pre-push node device also has the resources of the target live stream, so that the target live stream can be downloaded from the target pre-push node device. The server storing the target live stream and the target pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be relieved, and the bandwidth cost of the server is saved. On the other hand, the delay waiting time when each pre-push node device requests the live stream from the CDN server is set to be shorter than the delay waiting time when other node devices request the live stream from the CDN server, and each pre-push node device is in long-connection communication with the TCP server, and other node devices are not in communication with the TCP server, so that the pre-push node devices are advantageous in time when acquiring the live stream, and it is advantageous to fully utilize the upload bandwidth of the pre-push node device as peer-to-peer network output data, thereby further reducing server pressure.
Referring further to fig. 4, a flow 400 of yet another embodiment of a pre-push method is shown. The pre-push method is applied to a pre-push node device in a peer-to-peer network system, and the flow 400 of the pre-push method includes the following steps:
step 401, sending a pre-push task request including local information to a pre-push server.
In this embodiment, an executing agent of the pre-push method (e.g., each pre-push node device of the peer-to-peer network) may send a pre-push task request containing local information to the pre-push server. The local information may include, but is not limited to, a local upload bandwidth, an operator of a network used by the pre-push node device, a version of a live client installed in the pre-push node device, information indicating whether there is a live stream currently being downloaded, a reason for closing the pre-push operation last time, and the like.
Step 402, in response to receiving the pre-push task returned by the pre-push server, downloading the target live stream indicated by the pre-push task, and uploading the target live stream to a node device requesting the target live stream in the peer-to-peer network system.
In this embodiment, in response to receiving a pre-push task returned by the pre-push server, the execution main body may download a target live stream indicated by the pre-push task, and upload the target live stream to a node device requesting the target live stream in the peer-to-peer network system. In the process of downloading the target live stream and after the target live stream is finished, the target pre-push node equipment can upload the downloaded target live stream to node equipment requesting the target live stream in a peer-to-peer network system. Thus, the server is shared with pressure.
In some optional implementation manners of this embodiment, before sending the pre-push task request including the local information to the pre-push server, the execution main body may further perform the following operations: and sending first inquiry information to the pre-push server. The first query information is used for querying whether to start a pre-push operation; receiving response information returned by the pre-push server; and in response to determining that the response information indicates that the pre-push operation is not started, retransmitting the first inquiry information to the pre-push server at an interval of a first preset time length.
In some optional implementation manners of this embodiment, in the process of downloading and uploading the target live stream, the execution main body may further perform statistics on a pre-push condition every second preset time period, and send a statistical result to the data server, where the statistical result includes information for describing a downloading condition and information for describing an uploading condition.
In some optional implementation manners of this embodiment, the pre-push task may include configuration information, where configuration parameters in the configuration information include: and the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send the second inquiry information. The second query information is used to query whether the pre-push task needs to be updated.
In some optional implementation manners of this embodiment, after receiving a pre-push task returned by the pre-push server, the execution main body may further send the second query message to the pre-push server based on the waiting duration; then, second response information containing the updated pre-push task or third response information indicating that the pre-push task does not need to be updated may be received.
The method provided by the above embodiment of the present application, by executing the pre-push task by the pre-push node device in the peer-to-peer network system, can push the target live stream to the pre-push node device in advance. Therefore, when other node devices of the peer-to-peer network request the target live stream, the pre-push node device also has the resource of the target live stream, so that the target live stream can be downloaded from the pre-push node device. The server storing the target live stream and the pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be relieved, and the bandwidth cost of the server is saved.
With further reference to fig. 5, as an implementation of the methods shown in the above-mentioned figures, the present application provides an embodiment of a pre-push apparatus, where the embodiment of the apparatus corresponds to the embodiment of the method shown in fig. 4, and the apparatus may be specifically applied to various electronic devices (e.g., terminal devices).
As shown in fig. 5, the pre-pushing apparatus 500 according to the present embodiment includes: a first sending unit 501 configured to send a pre-push task request containing local information to a pre-push server; a first receiving unit 502, configured to, in response to receiving a pre-push task returned by the pre-push server, download a target live stream indicated by the pre-push task, and upload the target live stream to a node device in the peer-to-peer network system that requests the target live stream.
In some optional implementations of this embodiment, the apparatus may further include a second sending unit 503, a second receiving unit 504, and a third sending unit 505. The second sending unit is configured to send first query information to the pre-push server, where the first query information is used to query whether to start a pre-push operation; the second receiving unit is configured to receive response information returned by the pre-push server; and a third sending unit, configured to, in response to determining that the response information indicates that the pre-push operation is not started, resend the first query information to the pre-push server at an interval of a first preset time length.
In some optional implementations of this embodiment, the apparatus may further include a fourth sending unit 506. The fourth sending unit is configured to count the pre-push condition every second preset time length in the process of downloading and uploading the target live stream, and send a statistical result to the data server, where the statistical result includes information for describing the downloading condition and information for describing the uploading condition.
In some optional implementation manners of this embodiment, the pre-push task may further include configuration information, where configuration parameters in the configuration information include: and the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some optional implementations of this embodiment, the apparatus may further include a fifth sending unit 507 and a third receiving unit 508. The fifth sending unit is configured to send the second query information to the pre-push server based on the waiting duration; a third receiving unit configured to receive second response information including the updated pre-push task or third response information indicating that the pre-push task does not need to be updated.
The device provided by the embodiment of the application can pre-push the target live stream to the pre-push node equipment by pre-pushing the node equipment in the peer-to-peer network system to execute the pre-push task. Therefore, when other node devices of the peer-to-peer network request the target live stream, the pre-push node device also has the resource of the target live stream, so that the target live stream can be downloaded from the pre-push node device. The server storing the target live stream and the pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be relieved, and the bandwidth cost of the server is saved.
With further reference to fig. 6, a flow 600 of yet another embodiment of a pre-push method is illustrated. The pre-push method is applied to a pre-push server, and the flow 600 of the pre-push method includes the following steps:
step 601, receiving a pre-push task request sent by each pre-push node device in the peer-to-peer network system.
In this embodiment, an execution subject (e.g., a pre-push server) of the pre-push method may receive a pre-push task request sent by each pre-push node device in the peer-to-peer network system. Wherein, the pre-push task request includes local information. The local information may include, but is not limited to, a local upload bandwidth, an operator of a network used by the pre-push node device, a version of a live broadcast client installed in the pre-push node device, information indicating whether there is a live broadcast stream currently being downloaded, a reason for closing the pre-push operation last time, and the like.
Step 602, determining a target pre-push node device in the pre-push node devices based on the received local information, sending a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and uploading the target live stream to a node device requesting the target live stream in the peer-to-peer network system.
In this embodiment, the executing body may determine a target pre-push node device in the pre-push node devices based on the received local information of each pre-push node device. In practice, the pre-push server may determine the target pre-push node device based on various preset rules. The number of target pre-push node devices may be one or more.
Then, the execution body may send a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and uploads the target live stream to a node device requesting the target live stream in the peer-to-peer network system.
In some optional implementation manners of this embodiment, before receiving a pre-push task request sent by each pre-push node device in the peer-to-peer network system, the execution main body may further perform the following operations: and receiving first inquiry information sent by each pre-push node device. The first query message is used for querying whether a pre-push function is started. And then, returning the first response information to each pre-push server. The first response information is used for indicating whether to start response information of the pre-push function.
In some optional implementation manners of this embodiment, the executing entity may send the pre-push task to the target pre-push node device by: firstly, the number of users watching each live stream currently can be inquired; then, a target live stream to be pushed in advance can be determined based on the number of the users; and finally, sending a pre-push task for indicating pre-pushing of the target live stream to the target pre-push node equipment.
In some optional implementation manners of this embodiment, the pre-push task may further include configuration information, where configuration parameters in the configuration information include: and the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send the second inquiry information. The second query message is used to query whether the pre-push task needs to be updated.
In some optional implementation manners of this embodiment, after the pre-push task is sent to the target pre-push node device, the execution main body may further perform the following operation: receiving second inquiry information sent by the target pre-push node equipment; judging whether the target live stream needs to be updated or not; if so, updating the pre-push task, and returning second response information containing the updated pre-push task to the target pre-push node equipment; if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node equipment.
The method provided by the above embodiment of the present application, by executing the pre-push task by the pre-push node device in the peer-to-peer network system, can pre-push the target live stream to the target pre-push node device. Therefore, when other node devices of the peer-to-peer network request the target live stream, the target pre-push node device also has the resources of the target live stream, so that the target live stream can be downloaded from the target pre-push node device. The server storing the target live stream and the target pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be relieved, and the bandwidth cost of the server is saved.
With further reference to fig. 7, as an implementation of the methods shown in the foregoing figures, the present application provides an embodiment of a pre-push apparatus, where the embodiment of the apparatus corresponds to the embodiment of the method shown in fig. 6, and the apparatus may be specifically applied to various electronic devices (for example, terminal devices).
As shown in fig. 7, the pre-pushing apparatus 700 according to this embodiment includes: a first receiving unit 701, configured to receive a pre-push task request sent by each pre-push node device in a peer-to-peer network system, where the pre-push task request includes local information; a first sending unit 702, configured to determine, based on the received local information, a target pre-push node device of the one or more pre-push node devices, send a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and upload the target live stream to a node device in the peer-to-peer network system that requests the target live stream.
In some optional implementations of this embodiment, the apparatus may further include a second receiving unit 703 and a second sending unit 704. The second receiving unit is configured to receive first query information sent by each pre-push node device, where the first query information is used to query whether to start a pre-push function; and a second sending unit configured to return first response information to each pre-push server, where the first response information is used to indicate whether to start response information of the pre-push function.
In some optional implementations of this embodiment, the first sending unit 702 may include a querying module 7021, a determining module 7022, and a sending module 7023. The query module is configured to query the number of users currently watching each live stream; the determining module is configured to determine a pre-pushed target live stream based on the number of the users; and the sending module is configured to send a pre-push task for indicating pre-pushing of the target live stream to the target pre-push node device.
In some optional implementation manners of this embodiment, the pre-push task may further include configuration information, where configuration parameters in the configuration information include: and the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some optional implementations of this embodiment, the apparatus may further include a third receiving unit 705, a determining unit 706, a third sending unit 707, and a fourth sending unit 708. The third receiving unit is configured to receive second query information sent by the target pre-push node device; a determining unit configured to determine whether the target live stream needs to be updated; the third sending unit is configured to update the pre-push task and return second response information containing the updated pre-push task to the target pre-push node device if the pre-push task is updated; and if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node device.
The device provided by the above embodiment of the present application, through executing the pre-push task by the pre-push node device in the peer-to-peer network system, can push the target live stream to the target pre-push node device in advance. Therefore, when other node devices of the peer-to-peer network request the target live stream, the target pre-push node device also has the resources of the target live stream, so that the target live stream can be downloaded from the target pre-push node device. The server storing the target live stream and the target pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be relieved, and the bandwidth cost of the server is saved.
With further reference to FIG. 8, a flow diagram of one embodiment of a pre-push method in accordance with the present application is shown. The process 800 of the pre-push method includes the following steps:
step 801, each pre-push node device in the peer-to-peer network system sends a pre-push task request including local information to a pre-push server.
Step 802, the pre-push server determines a target pre-push node device of the one or more pre-push node devices based on the received local information, and sends a pre-push task to the target pre-push node device;
and 803, the target pre-push node device downloads the target live stream indicated by the pre-push task, and uploads the target live stream to the node device requesting the target live stream in the peer-to-peer network system.
It should be noted that the operations in steps 801 to 803 are substantially the same as the operations in steps 101 to 104, and are not described herein again.
In some optional implementation manners of this embodiment, each pre-push node device may further send first query information to the pre-push server before sending the pre-push task request including the local information to the pre-push server. Wherein the first query information may be used to query whether to start the pre-push operation. Then, receiving first response information which can be returned by the pre-push server; and in response to the fact that the first response information indicates that the pre-pushing operation is not started, retransmitting the first inquiry information to the pre-pushing server at intervals of a first preset duration.
In some optional implementation manners of this embodiment, the pre-push server may further query the number of users currently watching each live stream; determining a target live stream to be pushed in advance based on the number of users; and sending a pre-push task for indicating pre-push of the target live stream to the target pre-push node equipment.
In some optional implementation manners of this embodiment, the target pre-push node device may further perform statistics on pre-push conditions every second preset time period in a process of downloading and uploading a target live stream, and send a statistical result to the data server, where the statistical result includes information used for describing a downloading condition and information used for describing an uploading condition.
In some optional implementations of this embodiment, the pre-push task may further include configuration information. The configuration parameters in the configuration information may include: the target pre-push node uploads the specified data volume of the target video stream and the waiting time for the target pre-push node to send second inquiry information, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
In some optional implementation manners of this embodiment, the target pre-push node device may further send the second query information to the pre-push server based on the waiting duration. The pre-push server can judge whether the target live stream needs to be updated or not; if so, updating the pre-push task, and returning second response information containing the updated pre-push task to the target pre-push node equipment; if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node equipment.
In some optional implementation manners of this embodiment, the peer-to-peer network system may further include a content delivery network CDN server, each node device in the peer-to-peer network system is in communication connection with the CDN server, and a delay waiting duration when each pre-push node device requests a live stream from the CDN server is smaller than a delay waiting duration when another node device requests a live stream from the CDN server, where the another node device is a node device in the peer-to-peer network system except the pre-push node device.
In some optional implementation manners of this embodiment, the peer-to-peer network system may further include a TCP server, each pre-push node device is in communication connection with the TCP server in a long connection manner, and the other node devices are not in communication connection with the TCP server. And the TCP server responds to the received live stream acquisition request sent by the pre-push node equipment and can return the live stream indicated by the live stream acquisition request to the pre-push node equipment sending the live stream acquisition request.
According to the method provided by the embodiment of the application, the target live broadcast stream can be pushed to the target pre-push node equipment in advance by setting the pre-push node equipment in the peer-to-peer network system and selecting the target pre-push node equipment in the pre-push node equipment to execute the pre-push task. Since the target pre-push node device also has the resources of the target live stream, when other node devices of the peer-to-peer network request the target live stream, the target live stream can be downloaded from the target pre-push node device. The server storing the target live stream and the target pre-push node equipment can provide the target live stream at the same time, so that the pressure of the server can be effectively relieved.
Referring now to FIG. 9, shown is a block diagram of a computer system 900 suitable for use in implementing the electronic device of an embodiment of the present application. The electronic device shown in fig. 9 is only an example, and should not bring any limitation to the functions and the use range of the embodiment of the present application.
As shown in fig. 9, the computer system 900 includes a Central Processing Unit (CPU) 901 that can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM) 902 or a program loaded from a storage section 908 into a Random Access Memory (RAM) 903. In the RAM 903, various programs and data necessary for the operation of the system 900 are also stored. The CPU901, ROM 902, and RAM 903 are connected to each other via a bus 904. An input/output (I/O) interface 905 is also connected to bus 904.
The following components are connected to the I/O interface 905: an input portion 906 including a keyboard, a mouse, and the like; an output section 907 including a display such as a Liquid Crystal Display (LCD) and a speaker; a storage portion 908 including a hard disk and the like; and a communication section 909 including a network interface card such as a LAN card, a modem, or the like. The communication section 909 performs communication processing via a network such as the internet. The drive 910 is also connected to the I/O interface 905 as necessary. A removable medium 911 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 910 as necessary so that a computer program read out therefrom is mounted into the storage section 908 as necessary.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer-readable medium, the computer program comprising program code for performing the method illustrated by the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 909, and/or installed from the removable medium 911. The computer program performs the above-described functions defined in the method of the present application when executed by a Central Processing Unit (CPU) 901. It should be noted that the computer readable medium described herein can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the context of this application, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In this application, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems that perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present application may be implemented by software or hardware. The described units may also be provided in a processor, where the names of these units do not in some cases constitute a limitation of the unit itself.
As another aspect, the present application also provides a computer-readable medium, which may be contained in the apparatus described in the above embodiments; or may be present separately and not assembled into the device. The computer readable medium carries one or more programs which, when executed by the apparatus, cause the apparatus to: sending a pre-push task request containing local information to a pre-push server; and in response to receiving the pre-push task returned by the pre-push server, downloading the target live stream indicated by the pre-push task, and uploading the target live stream to the node equipment requesting the target live stream in the peer-to-peer network system. Or, causing the apparatus to: receiving pre-push task requests sent by each pre-push node device in a peer-to-peer network system, wherein the pre-push task requests comprise local information; and determining a target pre-push node device in the one or more pre-push node devices based on the received local information, sending a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and uploading the target live stream to a node device requesting the target live stream in the peer-to-peer network system.
The foregoing description is only exemplary of the preferred embodiments of the application and is illustrative of the principles of the technology employed. It will be appreciated by those skilled in the art that the scope of the invention herein disclosed is not limited to the particular combination of features described above, but also encompasses other arrangements formed by any combination of the above features or their equivalents without departing from the spirit of the invention. For example, the above features may be replaced with (but not limited to) features having similar functions disclosed in the present application.

Claims (20)

1. A pre-push system is characterized by comprising a peer-to-peer network system and a pre-push server, wherein the peer-to-peer network system comprises a plurality of node devices, the plurality of node devices comprise one or more pre-push node devices, and the pre-push node device is a node device starting a pre-push function in the plurality of node devices;
each pre-push node device configured to send a pre-push task request containing local information to the pre-push server; the local information comprises the reason for closing the pre-push operation last time;
the pre-push server is configured to analyze pre-push quality of each pre-push node device based on the received local information, determine a target pre-push node device of the one or more pre-push node devices, and send a pre-push task to the target pre-push node device; the pre-push task comprises an identification or a name of a target live stream and is used for indicating the target pre-push node equipment to download the target live stream; the target live broadcast stream is obtained by inquiring the bandwidth pressure of each server providing live broadcast stream downloading, or the live broadcast stream with the user number larger than a preset threshold value is taken as the target live broadcast stream;
each pre-push node device is further configured to send first query information to the pre-push server, where the first query information is used to query whether to start a pre-push operation; receiving first response information returned by the pre-push server; in response to determining that the first response information indicates that the pre-pushing operation is not started, resending the first query information to the pre-pushing server at intervals of a first preset duration;
the target pre-push node device is configured to download the target live stream indicated by the pre-push task from a CDN server and a TCP server, and upload the target live stream to a node device requesting the target live stream in the peer-to-peer network system, where each pre-push node device is in communication connection with the TCP server in a long connection manner, and other node devices are not in communication connection with the TCP server, where the other node devices are node devices in the peer-to-peer network system except the pre-push node devices.
2. The pre-push system of claim 1, wherein the pre-push server is further configured to: inquiring the number of users currently watching each live stream; determining a target live stream to be pushed in advance based on the number of the users; and sending a pre-pushing task for indicating pre-pushing of the target live stream to the target pre-pushing node equipment.
3. The pre-push system of claim 2, further comprising a data server; and
the target pre-push node device, further configured to: in the process of downloading and uploading the target live stream, counting the pre-pushing condition every second preset time length, and sending a counting result to a data server, wherein the counting result comprises information for describing the downloading condition and information for describing the uploading condition.
4. The pre-push system of claim 2, wherein the pre-push task further comprises configuration information, and configuration parameters in the configuration information comprise: the target pre-push node uploads the specified data volume of the target live stream and the waiting time of sending second inquiry information by the target pre-push node, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
5. The pre-push system of claim 4,
the target pre-push node device, further configured to: sending the second inquiry information to the pre-push server based on the waiting time length; and
the pre-push server is further configured to judge whether the target live stream needs to be updated; if yes, updating the pre-push task, and returning second response information containing the updated pre-push task to the target pre-push node equipment; and if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node equipment.
6. The pre-push system of claim 1, wherein the peer-to-peer network system further includes a Content Delivery Network (CDN) server, each node device in the peer-to-peer network system is in communication connection with the CDN server, and a delay waiting duration when each pre-push node device requests the CDN server for a live stream is shorter than a delay waiting duration when other node devices request the CDN server for a live stream.
7. The pre-push system of claim 1, wherein the peer-to-peer network system further comprises a Transmission Control Protocol (TCP) server, and the TCP server is configured to, in response to receiving a live stream acquisition request sent by a pre-push node device, return a live stream indicated by the live stream acquisition request to the pre-push node device that sent the live stream acquisition request.
8. A pre-push method is applied to a pre-push node device in a peer-to-peer network system, wherein the peer-to-peer network system comprises a plurality of node devices, the plurality of node devices comprise one or more pre-push node devices, and the pre-push node device is a node device which starts a pre-push function in the plurality of node devices; the method comprises the following steps:
sending a pre-push task request containing local information to a pre-push server; the local information comprises the reason for closing the pre-push operation last time;
sending first inquiry information to the pre-push server, wherein the first inquiry information is used for inquiring whether a pre-push operation is started or not; receiving first response information returned by the pre-push server; in response to determining that the first response information indicates that the pre-pushing operation is not started, resending the first query information to the pre-pushing server at intervals of a first preset duration;
in response to receiving a pre-push task returned by the pre-push server, downloading a target live stream indicated by the pre-push task from a CDN server and a TCP server, and uploading the target live stream to node equipment requesting the target live stream in the peer-to-peer network system; each pre-push node device is in communication connection with the TCP server in a long connection mode, and other node devices are not in communication connection with the TCP server; the pre-push task comprises an identification or a name of a target live stream and is used for indicating target pre-push node equipment to download the target live stream; the target live broadcast stream is obtained by inquiring the bandwidth pressure of each server providing live broadcast stream downloading, or the live broadcast stream with the user number larger than a preset threshold value is taken as the target live broadcast stream; the target pre-push node device analyzes the pre-push quality of each pre-push node device through the pre-push server based on the received local information, and then selects from the one or more pre-push node devices according to the pre-push quality.
9. The pre-push method of claim 8, further comprising:
in the process of downloading and uploading the target live stream, counting the pre-pushing condition every second preset time length, and sending a counting result to a data server, wherein the counting result comprises information for describing the downloading condition and information for describing the uploading condition.
10. The pre-push method according to claim 8, wherein the pre-push task further includes configuration information, and configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target live stream and the waiting time of sending second inquiry information by the target pre-push node, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
11. The pre-push method of claim 10, wherein after the pre-push task returned by the pre-push server is received in response to the receiving, the method further comprises:
sending the second inquiry information to the pre-push server based on the waiting duration;
and receiving second response information containing the updated pre-push task or third response information used for indicating that the pre-push task does not need to be updated.
12. A pre-push apparatus is applied to a pre-push node device in a peer-to-peer network system, where the peer-to-peer network system includes a plurality of node devices, the plurality of node devices includes one or more pre-push node devices, and the pre-push node device is a node device that starts a pre-push function among the plurality of node devices; the device comprises:
a first sending unit configured to send a pre-push task request containing local information to a pre-push server; the local information comprises the reason for closing the pre-push operation last time;
sending first inquiry information to the pre-push server, wherein the first inquiry information is used for inquiring whether a pre-push operation is started or not; receiving first response information returned by the pre-push server; in response to determining that the first response information indicates that the pre-pushing operation is not started, resending the first query information to the pre-pushing server at intervals of a first preset duration;
a first receiving unit, configured to, in response to receiving a pre-push task returned by the pre-push server, download a target live stream indicated by the pre-push task from a CDN server and a TCP server, and upload the target live stream to a node device in the peer-to-peer network system that requests the target live stream; each pre-push node device is in communication connection with the TCP server in a long connection mode, and other node devices are not in communication connection with the TCP server; the pre-push task comprises an identification or a name of a target live stream and is used for indicating target pre-push node equipment to download the target live stream; the target live broadcast stream is obtained by inquiring the bandwidth pressure of each server providing live broadcast stream downloading, or the live broadcast stream with the user number larger than a preset threshold value is taken as the target live broadcast stream; the target pre-push node device analyzes the pre-push quality of each pre-push node device based on the received local information through the pre-push server, and then selects from the one or more pre-push node devices according to the pre-push quality.
13. A pre-push method is applied to a pre-push server, and the system comprises a peer-to-peer network system and the pre-push server, wherein the peer-to-peer network system comprises a plurality of node devices, the plurality of node devices comprise one or more pre-push node devices, and the pre-push node devices are node devices which start a pre-push function among the plurality of node devices; the method comprises the following steps:
receiving first inquiry information sent by each pre-push node device, wherein the first inquiry information is used for inquiring whether a pre-push function is started or not;
returning first response information to each pre-push server, wherein the first response information is used for indicating whether response information of the pre-push function is started or not;
receiving pre-push task requests sent by each pre-push node device in a peer-to-peer network system, wherein the pre-push task requests comprise local information; the local information comprises the reason for closing the pre-push operation last time;
analyzing the pre-push quality of each pre-push node device based on the received local information, determining a target pre-push node device in the one or more pre-push node devices, sending a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and uploading the target live stream to a node device requesting the target live stream in the peer-to-peer network system; the pre-push task comprises an identification or a name of a target live stream and is used for indicating the target pre-push node equipment to download the target live stream; the target live stream is obtained by inquiring the bandwidth pressure of each server providing live stream downloading, or the live stream with the user number larger than a preset threshold value is used as the target live stream.
14. The pre-push method according to claim 13, wherein the sending the pre-push task to the target pre-push node device comprises:
inquiring the number of users currently watching each live stream;
determining a target live stream to be pushed in advance based on the number of the users;
and sending a pre-push task for indicating pre-pushing of the target live stream to the target pre-push node equipment.
15. The pre-push method according to claim 13, wherein the pre-push task further includes configuration information, and configuration parameters in the configuration information include: the target pre-push node uploads the specified data volume of the target live stream and the waiting time of sending second inquiry information by the target pre-push node, wherein the second inquiry information is used for inquiring whether the pre-push task needs to be updated or not.
16. The pre-push method according to claim 15, wherein after the sending of the pre-push task to the target pre-push node device, the method further comprises:
receiving second inquiry information sent by the target pre-push node equipment;
judging whether the target live stream needs to be updated or not;
if yes, updating the pre-pushing task, and returning second response information containing the updated pre-pushing task to the target pre-pushing node equipment;
and if not, returning third response information for indicating that the pre-push task does not need to be updated to the target pre-push node equipment.
17. A pre-push device is characterized in that the pre-push device is arranged in a pre-push server, the system comprises a peer-to-peer network system and the pre-push server, the peer-to-peer network system comprises a plurality of node devices, the plurality of node devices comprise one or more pre-push node devices, and the pre-push node devices are node devices starting a pre-push function in the plurality of node devices; the device comprises:
a first receiving unit, configured to receive a pre-push task request sent by each pre-push node device in a peer-to-peer network system, where the pre-push task request includes local information; the local information comprises the reason for closing the pre-push operation last time;
a first sending unit, configured to analyze a pre-push quality of each pre-push node device based on the received local information, determine a target pre-push node device of the one or more pre-push node devices, send a pre-push task to the target pre-push node device, so that the target pre-push node device downloads a target live stream indicated by the pre-push task, and upload the target live stream to a node device in the peer-to-peer network system that requests the target live stream; the pre-push task comprises an identification or a name of a target live stream and is used for indicating the target pre-push node equipment to download the target live stream; the target live broadcast stream is obtained by inquiring the bandwidth pressure of each server providing live broadcast stream downloading, or the live broadcast stream with the user number larger than a preset threshold value is taken as the target live broadcast stream;
the first receiving unit is further configured to receive first query information sent by each pre-push node device, where the first query information is used to query whether to start a pre-push function;
the first sending unit is further configured to return first response information to each pre-push server, where the first response information is used to indicate response information of whether to start the pre-push function.
18. A pre-push method is characterized in that the system comprises a peer-to-peer network system and a pre-push server, wherein the peer-to-peer network system comprises a plurality of node devices, the plurality of node devices comprise one or more pre-push node devices, and the pre-push node devices are node devices starting a pre-push function in the plurality of node devices; the method comprises the following steps:
each pre-push node device in the peer-to-peer network system sends a pre-push task request containing local information to the pre-push server; the local information comprises the reason for closing the pre-push operation last time;
the pre-push server analyzes the pre-push quality of each pre-push node device based on the received local information, determines a target pre-push node device in the one or more pre-push node devices, and sends a pre-push task to the target pre-push node device; the pre-push task comprises an identification or a name of a target live stream and is used for indicating the target pre-push node equipment to download the target live stream; the target live broadcast stream is obtained by inquiring the bandwidth pressure of each server providing live broadcast stream downloading, or the live broadcast stream with the user number larger than a preset threshold value is taken as the target live broadcast stream;
each pre-push node device sends first inquiry information to the pre-push server, wherein the first inquiry information is used for inquiring whether a pre-push operation is started or not; receiving first response information returned by the pre-push server; in response to determining that the first response information indicates that the pre-pushing operation is not started, resending the first query information to the pre-pushing server at intervals of a first preset duration;
target pre-push node equipment downloads a target live stream indicated by the pre-push task from a CDN server and a TCP server, uploads the target live stream to node equipment requesting the target live stream in the peer-to-peer network system, wherein the pre-push node equipment is in communication connection with the TCP server in a long connection mode, and other node equipment is not in communication connection with the TCP server, and the other node equipment is node equipment except the pre-push node equipment in the peer-to-peer network system.
19. An electronic device, comprising:
one or more processors;
a storage device having one or more programs stored thereon,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 8-11, 13-16, 18.
20. A computer-readable medium, on which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 8-11, 13-16, 18.
CN201910351574.6A 2019-04-28 2019-04-28 Pre-push system, method, device, electronic equipment and computer readable medium Active CN110213330B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910351574.6A CN110213330B (en) 2019-04-28 2019-04-28 Pre-push system, method, device, electronic equipment and computer readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910351574.6A CN110213330B (en) 2019-04-28 2019-04-28 Pre-push system, method, device, electronic equipment and computer readable medium

Publications (2)

Publication Number Publication Date
CN110213330A CN110213330A (en) 2019-09-06
CN110213330B true CN110213330B (en) 2023-02-03

Family

ID=67786658

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910351574.6A Active CN110213330B (en) 2019-04-28 2019-04-28 Pre-push system, method, device, electronic equipment and computer readable medium

Country Status (1)

Country Link
CN (1) CN110213330B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114679598B (en) * 2022-03-24 2023-11-21 上海哔哩哔哩科技有限公司 Live broadcast pushing method and device
CN114827649B (en) * 2022-04-22 2024-02-23 上海哔哩哔哩科技有限公司 Method and device for constructing live peer-to-peer network, electronic equipment and storage medium

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2010136023A1 (en) * 2009-05-25 2010-12-02 Lysatiq Gmbh Method for optimizing a packet-oriented data transmission and computer program product

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101247193B (en) * 2008-02-28 2010-12-08 华为技术有限公司 Method, system, node and super node for transmitting data in peer-to-peer network
CN102387164B (en) * 2010-08-30 2014-05-14 上海悠络客电子科技有限公司 Method for transmitting peer-to-peer (p2p) network data
US9654329B2 (en) * 2012-05-04 2017-05-16 The Hong Kong University Of Science And Technology Content distribution over a network
US20140344399A1 (en) * 2012-12-13 2014-11-20 Level 3 Communications, Llc Origin Server-Side Channel In A Content Delivery Framework
CN106412060A (en) * 2016-09-28 2017-02-15 上海赛特斯信息科技股份有限公司 Peer-to-peer (P2P) network system and method for realizing active loading of content based on intelligent strategy
CN107623723B (en) * 2017-08-21 2019-05-24 腾讯科技(深圳)有限公司 Transmission method and device, the storage medium and electronic device of net cast data

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2010136023A1 (en) * 2009-05-25 2010-12-02 Lysatiq Gmbh Method for optimizing a packet-oriented data transmission and computer program product

Also Published As

Publication number Publication date
CN110213330A (en) 2019-09-06

Similar Documents

Publication Publication Date Title
US11356748B2 (en) Method, apparatus and system for slicing live streaming
CN108696374B (en) Method and device for updating client configuration
CN108173774B (en) Client upgrading method and system
CN110247985B (en) Resource downloading method and device, electronic equipment and medium
US8589477B2 (en) Content information display device, system, and method used for creating content list information based on a storage state of contents in a cache
CN113132489A (en) Method, device, computing equipment and medium for downloading file
WO2010077379A1 (en) Systems and methods for peer-to-peer bandwidth allocation
CN108462755B (en) Method and system for downloading data resources
CN110493321B (en) Resource acquisition method, edge scheduling system and server
CN109982152B (en) P2P CDN service processing method, intelligent gateway and CDN platform
US20180278692A1 (en) Communication device, communication system, and communication method
CN110213330B (en) Pre-push system, method, device, electronic equipment and computer readable medium
WO2017097210A1 (en) Method, apparatus and system for upgrading software
CN102739717A (en) Downloading method, downloading proxy server and network system
EP3120519B1 (en) Method for operating a cache arranged along a transmission path between client terminals and at least one server, and corresponding cache
CN103095785B (en) Remote procedure calling (PRC) method and system, client and server
CN103826139A (en) CDN system, watching server and streaming media data transmission method
KR100823730B1 (en) Method and apparatus for providing streaming service based on P2P, and streaming service system using the same
CN108156257B (en) Information pushing method and device
CN110392020B (en) Streaming media resource transmission method and system
CN109471713B (en) Method and device for inquiring information
CN110740138B (en) Data transmission method and device
CN112769958A (en) Point-to-point network scheduling method and system
CN109995824B (en) Task scheduling method and device in peer-to-peer network
CN113747252B (en) Method, device and system for transmitting multimedia resources

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