CN110602515B - Data processing method based on block chain, server and storage medium - Google Patents

Data processing method based on block chain, server and storage medium Download PDF

Info

Publication number
CN110602515B
CN110602515B CN201910869594.2A CN201910869594A CN110602515B CN 110602515 B CN110602515 B CN 110602515B CN 201910869594 A CN201910869594 A CN 201910869594A CN 110602515 B CN110602515 B CN 110602515B
Authority
CN
China
Prior art keywords
video
target
stream data
video stream
block
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
CN201910869594.2A
Other languages
Chinese (zh)
Other versions
CN110602515A (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910869594.2A priority Critical patent/CN110602515B/en
Publication of CN110602515A publication Critical patent/CN110602515A/en
Application granted granted Critical
Publication of CN110602515B publication Critical patent/CN110602515B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/21Server components or server architectures
    • H04N21/218Source of audio or video content, e.g. local disk arrays
    • H04N21/2187Live feed
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/232Content retrieval operation locally within server, e.g. reading video streams from disk arrays
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/239Interfacing the upstream path of the transmission network, e.g. prioritizing client content requests
    • H04N21/2393Interfacing the upstream path of the transmission network, e.g. prioritizing client content requests involving handling client requests
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/25Management operations performed by the server for facilitating the content distribution or administrating data related to end-users or client devices, e.g. end-user or client device authentication, learning user preferences for recommending movies
    • H04N21/262Content or additional data distribution scheduling, e.g. sending additional data at off-peak times, updating software modules, calculating the carousel transmission frequency, delaying a video stream transmission, generating play-lists

Abstract

The embodiment of the invention provides a data processing method based on a block chain, a server and a storage medium, wherein the method comprises the following steps: responding to a video playing request sent by a client, and acquiring request time information of a requested live video, wherein the video playing request carries an identifier of the live video; inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video; screening the at least one block to obtain a target block, wherein the target block comprises target video stream data of the live broadcast video and playing time information of the target video stream data, and the playing time information is matched with the request time information; and sending the target video stream data in the target block to the client. The embodiment of the invention can realize the transmission of the video stream data based on the block chain network and increase the diversity of the transmission of the video stream data.

Description

Data processing method based on block chain, server and storage medium
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data processing method based on a block chain, a server, and a storage medium.
Background
With the wide application of intelligent terminals (such as smart phones, tablet computers, and the like) and the development of internet technologies, live video services are becoming more and more popular. The video live broadcast refers to live broadcast by using the internet and a streaming media technology, and the video gradually becomes a mainstream expression mode of the internet due to the fact that rich elements such as images, sounds and characters are fused. The live video broadcast relates to a plurality of technologies such as acquisition, coding and compression of audio and video data, transmission and decoding of video stream data and the like. The transmission technology of the video stream data involved therein is a current research hotspot.
Disclosure of Invention
The embodiment of the invention provides a data processing method based on a block chain, a server and a storage medium, which can realize the transmission of video stream data based on a block chain network and increase the diversity of the transmission of the video stream data.
In one aspect, an embodiment of the present invention provides a data processing method based on a block chain, where the method includes:
responding to a video playing request sent by a client, and acquiring request time information of a requested live video, wherein the video playing request carries an identifier of the live video;
inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video;
screening the at least one block to obtain a target block, wherein the target block comprises target video stream data of the live broadcast video and playing time information of the target video stream data, and the playing time information is matched with the request time information;
and sending the target video stream data in the target block to the client.
In another aspect, an embodiment of the present invention provides a data processing apparatus based on a block chain, where the apparatus includes:
the system comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for responding to a video playing request sent by a client to acquire request time information of a requested live video, and the video playing request carries an identifier of the live video;
the processing unit is used for inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video;
the processing unit is further configured to filter the at least one block to obtain a target block, where the target block includes target video stream data of the live video and play time information of the target video stream data, and the play time information is matched with the request time information;
and the transceiving unit is used for sending the target video stream data in the target block to the client.
In another aspect, an embodiment of the present invention provides a server, including: the data processing system comprises a processor, a communication interface and a memory, wherein the processor, the communication interface and the memory are connected with each other, executable program codes are stored in the memory, and the processor is used for calling the executable program codes and executing the data processing method based on the block chain.
Accordingly, an embodiment of the present invention further provides a storage medium, where instructions are stored in the storage medium, and when the storage medium is run on a computer, the storage medium causes the computer to execute the above data processing method based on a block chain.
The embodiment of the invention inquires at least one block for storing the video stream data of the live video from the block chain network, screens out the target block with the playing time information of the stored video stream data matched with the request time information from the at least one block, and sends the target video stream data in the target block to the client, thereby realizing the transmission of the video stream data based on the block chain network and increasing the diversity of the video stream data transmission.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a block diagram of a data processing system according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of a block chain block according to an embodiment of the present invention;
fig. 3 is a schematic flowchart of a data processing method based on a block chain according to an embodiment of the present invention;
fig. 4 is a schematic flowchart of another data processing method based on a blockchain according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of a data processing apparatus based on a block chain according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of a server according to an embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
The embodiment of the invention provides a data processing system which can be a distributed system formed by connecting a live broadcast terminal, a client and a plurality of nodes (computing equipment in any form in an access network, such as a server and a user terminal) in a network communication form. The distributed system may be a blockchain system, and referring to fig. 1, fig. 1 is an optional architecture diagram of the data processing system applied to the blockchain system (or blockchain network) according to the embodiment of the present invention, and is formed by a live broadcast terminal, a plurality of nodes, and a client. A point-To-point (P2P, Peer To Peer) network is formed among the nodes, and the P2P Protocol is an application layer Protocol operating on a Transmission Control Protocol (TCP). In a distributed system, any machine, such as a server or a terminal, can join to become a node, and the node comprises a hardware layer, a middle layer, an operating system layer and an application layer.
Referring to the functions of each node in the blockchain system shown in fig. 1, the functions involved include:
1) routing, a basic function that a node has, is used to support communication between nodes.
Besides the routing function, the node may also have the following functions:
2) the application is used for being deployed in a block chain, realizing specific services according to actual service requirements, recording data related to the realization functions to form recording data, carrying a digital signature in the recording data to represent a source of task data, and sending the recording data to other nodes in the block chain system, so that the other nodes add the recording data to a temporary block when the source and integrity of the recording data are verified successfully.
For example, the services implemented by the application include:
2.1) wallet, for providing the function of transaction of electronic money, including initiating transaction (i.e. sending the transaction record of current transaction to other nodes in the blockchain system, after the other nodes are successfully verified, storing the record data of transaction in the temporary blocks of the blockchain as the response of confirming the transaction is valid; of course, the wallet also supports the querying of the remaining electronic money in the electronic money address;
and 2.2) sharing the account book, wherein the shared account book is used for providing functions of operations such as storage, query and modification of account data, record data of the operations on the account data are sent to other nodes in the block chain system, and after the other nodes verify the validity, the record data are stored in a temporary block as a response for acknowledging that the account data are valid, and confirmation can be sent to the node initiating the operations.
2.3) Intelligent contracts, computerized agreements, which can enforce the terms of a contract, implemented by codes deployed on a shared ledger for execution when certain conditions are met, for completing automated transactions according to actual business requirement codes, such as querying the logistics status of goods purchased by a buyer, transferring the buyer's electronic money to the merchant's address after the buyer signs for the goods; of course, smart contracts are not limited to executing contracts for trading, but may also execute contracts that process received information.
3) And the Block chain comprises a series of blocks (blocks) which are mutually connected according to the generated chronological order, new blocks cannot be removed once being added into the Block chain, and recorded data submitted by nodes in the Block chain system are recorded in the blocks.
Referring to fig. 2, fig. 2 is an optional schematic diagram of a Block Structure (Block Structure) according to an embodiment of the present invention, where each Block includes a hash value of a data record stored in the Block (hash value of the Block) and a hash value of a previous Block, and the blocks are connected by the hash values to form a Block chain. The block may include information such as a time stamp at the time of block generation. A block chain (Blockchain), which is essentially a decentralized database, is a string of data blocks associated by using cryptography, and each data block contains related information for verifying the validity (anti-counterfeiting) of the information and generating a next block.
In the embodiment of the invention, in the process of live broadcasting of a live broadcasting terminal, the video stream data of the live broadcasting video is stored in at least one block in the block chain network, and the video stream data stored in all the blocks in the at least one block are combined according to the playing time sequence to form the complete video stream data of the live broadcasting video. The client requests video stream data of live video from a node server in the blockchain network, and the node server acquires corresponding video stream data from the blockchain network and sends the corresponding video stream data to the client so that the client can play the live video according to the video stream data sent by the node server. By the above manner, the transmission of the video stream data can be realized based on the blockchain network, and the diversity of the transmission of the video stream data is increased, which will be described in detail below.
Referring to fig. 3, fig. 3 is a flowchart illustrating a data processing method based on a block chain according to a first embodiment of the present invention. The data processing method based on the blockchain described in the embodiment of the present invention may be applied to a node server, which may be any node of the blockchain network in the data processing system shown in fig. 1. In other embodiments, the node server is an optimal node determined according to a load condition, a response time, and a distance from a client of each node in the block chain network.
Before or during the data processing method in the embodiment of the present invention is executed by the node server, the video stream data of the live video is stored in a block in the block chain network, and the specific implementation manner may be: in the process of live broadcasting video on a live broadcasting terminal, audio and video data of the environment where the live broadcasting terminal is located are collected in real time through audio and video data collection equipment configured on the live broadcasting terminal, the live broadcasting terminal can be a computer or a smart phone and other terminals, and the audio and video data collection equipment comprises shooting equipment (such as a camera) and pickup equipment (such as a microphone); after audio and video data with preset time (for example, 3s) are obtained, the audio and video data with the preset time are subjected to quantization, coding, transcoding, packaging and other processing, and a section of video stream data of a live video is obtained; and recording the playing time information corresponding to the video stream data and the identification of the live video, wherein the playing time information is used for indicating the playing time of the live video in the video stream data.
Further, generating a block based on the segment of video stream data, wherein the block stores the segment of video stream data, playing time information corresponding to the segment of video stream data and an identifier of a live video; adding the block into a local block chain, so that other nodes in a block chain network can share the block, and each node can acquire the video stream data of the live video through the block; therefore, no matter which node in the blockchain network is accessed by the client, the client can acquire the video stream data of the live video. In one embodiment, the video stream data of the live video may be synchronized to a node in the blockchain network, so that the node accessed by the client directly acquires the video stream data of the live video from the local.
It should be noted that the above steps may be executed by a live terminal, where the live terminal is a node in a block chain network. The above steps can also be executed by a live broadcast server connected with the live broadcast terminal, and the live broadcast server is a node in the block chain network. In the above step, the live broadcast terminal or the live broadcast server may further generate the segment of video stream data, send the segment of video stream data to a first node in the block chain network, and then execute the step of generating the block based on the segment of video stream data and uplink by the first node. The first node may be any node in the block chain network, or a node closest to the live broadcast terminal or the server in the block chain network; the first node and the node server may be the same or different.
The data processing method based on the block chain described in the embodiment of the invention comprises the following steps:
s301, responding to a video playing request sent by a client, and acquiring request time information of a requested live video, wherein the video playing request carries an identifier of the live video.
In the embodiment of the present invention, the identifier is used to indicate a live video requested by the client, that is, a live video that the client user wants to watch. When a client receives a selection operation of a client user on a video live link, taking a live video selected by the selection operation as a requested live video, and acquiring an identifier of the requested live video; the identification may be a link or the like corresponding to the requested live video, and may be a string that uniquely identifies the requested live video. The client generates a video playing request carrying the identifier and sends the video playing request to the node server.
After receiving a video playing request sent by a client, a node server responds to the video playing request and acquires the identification of a live video requested by the video playing request and request time information. The request time information is used to indicate the start time of the requested live video, i.e., the time point at which the live video is required to start playing.
In an embodiment, a node server obtains sending time or receiving time of the video playing request, where the sending time may be carried in the video playing request; and then determining the request time information of the requested live video according to the acquired sending time or receiving time, wherein the sending time or the receiving time can be used as the playing starting time requested by the request time information, and based on the playing starting time, the latest video stream data of the live video can be requested from the node server, so that the client user can watch the latest live content conveniently.
In another embodiment, the video playing request further carries request time information of a live video, and the node server may directly obtain the request time information from the video playing request. In the process of playing a live video by a client, when the dragging operation of a progress bar in a video playing interface by a client user is detected, a review time point selected by the dragging operation is obtained, and the review time point is used for indicating the time point from which the live video is reviewed; and generating request time information according to the review time point, wherein the start playing time of the live video requested by the request time information is earlier than the sending time of the video playing request. The client generates a video playing request carrying live video identification and the request time information, and sends the video playing request to the node server. Based on this, historical video stream data of the live video may be requested from the node server to facilitate the client user to review the live content.
S302, inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video.
In the embodiment of the invention, a node server inquires a locally stored block chain according to an identifier of a live video, detects whether a block for storing video stream data of the live video requested by a client exists or not, and if so, acquires at least one block for storing the video stream data of the live video requested by the client in the local block chain; otherwise, at least one block for storing the video stream data of the live video requested by the client is inquired from a second node in the blockchain network, wherein the second node can be any node except the node server in the blockchain network or a node which is closer to the node server in the blockchain network. And the video stream data stored in all the blocks in the at least one block are combined according to the playing time sequence to form the complete video stream data of the live video.
S303, a target block is obtained by screening from the at least one block, the target block comprises target video stream data of the live broadcast video and playing time information of the target video stream data, and the playing time information is matched with the request time information.
In this embodiment of the present invention, the matching between the playing time information of the target video stream data and the request time information may be: the start playing time indicated by the request time information is within the playing period indicated by the playing time information or earlier than the earliest time in the playing period. For example, the client requests to play a live video at point 19: 02 and beyond if the at least one block of video stream data for storing live video comprises: stored video stream data is live video in time period 19: 00-19: 05, stored video stream data as live video at point in time 19: a second block of content preceding 00; the first block is determined as the target block. If at least one chunk of video stream data for storing live video comprises: stored video stream data is live video in time period 19: 00-19: 05, stored video stream data as live video at point in time 19: the second chunk of content before 00, and the stored video stream data is live video at time point 19: a third block of content after 05; the first block and the third block are determined as target blocks.
S304, sending the target video stream data in the target block to the client.
Correspondingly, the client receives target video stream data sent by the node server and plays live video based on the target video stream data.
In the embodiment of the invention, when a plurality of target blocks are obtained by screening, the node server can sequentially send the target video stream data in each target block to the client according to the sequence of the playing time indicated by the playing time information of the target video stream data in the plurality of target blocks, so that the problem that the video playing is not smooth as the client receives the video stream data with the playing time first can be avoided to a certain extent.
The embodiment of the invention inquires at least one block for storing the video stream data of the live video from the block chain network, screens out the target block with the playing time information of the stored video stream data matched with the request time information from the at least one block, and sends the target video stream data in the target block to the client, thereby realizing the transmission of the video stream data based on the block chain network and increasing the diversity of the video stream data transmission.
Referring to fig. 4, fig. 4 is a flowchart illustrating a data processing method based on a block chain according to a second embodiment of the present invention. Before or during the execution of the data processing method based on the block chain, video stream data of live videos at different viewing angles are stored in blocks in a block chain network, and the specific implementation manner may be: in the process of live broadcasting video of the live broadcasting terminal, audio and video data of the environment where the live broadcasting terminal is located are collected in real time from at least two shooting visual angles through audio and video data collection equipment configured on the live broadcasting terminal. For the audio and video data collected from each shooting visual angle, after the audio and video data with the preset time duration at a certain shooting visual angle is obtained, the audio and video data with the preset time duration at the shooting visual angle are subjected to quantization, coding, transcoding, packaging and other processing, and a section of video stream data of the live video at the shooting visual angle is obtained; and recording the shooting visual angle information, the playing time information and the identification of the live video corresponding to the video stream data. The playing time information is used for indicating the video stream data is the content of which playing time of the live video. The shooting angle information is used to indicate at which shooting angle the video stream data was shot.
Further, generating a block based on the video stream data, wherein the block stores the video stream data, the shooting visual angle information corresponding to the video stream data, the playing time information and the identification of the live video; the block is added into a local block chain, so that other nodes in a block chain network can share the block, and each node can acquire the video stream data of the live video under the shooting view angle through the block, and therefore a client can acquire the video stream data of the live video under the shooting view angle no matter which node is accessed into the block chain network. In some possible embodiments, the tile or the segment of video stream data may also be synchronized to each node in the blockchain network, so that the node accessed by the client directly acquires the video stream data of the live video in the shooting view from the local.
The video stream data under different shooting visual angles corresponding to the same time period can be respectively stored in different blocks, and the shooting visual angle information is utilized for identification; or storing the video stream data corresponding to the same time period under different shooting angles into the same block, and identifying by using the shooting angle information. Through the mode, the live video content under different shooting visual angles can be stored in the block chain network, so that a user can randomly switch different visual angles to watch the live video when watching the live video. It should be noted that the above steps may be executed by a live terminal, where the live terminal is a node in a block chain network. The above steps can also be executed by a live broadcast server connected with the live broadcast terminal, and the live broadcast server is a node in the block chain network. In the above step, the live broadcast terminal or the live broadcast server may further generate the segment of video stream data, send the segment of video stream data to a first node in the block chain network, and then execute the step of generating the block based on the segment of video stream data and uplink by the first node. The first node may be any node in the block chain network, or a node closest to the live broadcast terminal or the server in the block chain network; the first node and the node server may be the same or different.
The data processing method based on the block chain described in the embodiment of the invention comprises the following steps:
s401, a client sends a video playing request to a node server, wherein the video playing request carries an identification of a requested live video and requested view angle information of the requested live video.
In an embodiment of the invention, a node server may be any node of a blockchain network in the data processing system shown in FIG. 1. In other embodiments, the node server is an optimal node determined according to the load condition, response time and distance from the client of each node in the blockchain network, so as to improve the efficiency of video stream data transmission and balance the load of each node. The identifier is used to indicate the live video requested by the client, i.e., the live video that the client user wants to watch. The identification may be a link or the like corresponding to the requested live video, and may be a string that uniquely identifies the requested live video. The requested view information is used to indicate a viewing view of the live video requested by the client, where the viewing view may be a default viewing view of the client video player or a viewing view selected by the client user. Typically the viewing perspective is the same as the shooting perspective of the live video.
S402, the node server responds to the video playing request sent by the client, and obtains the request time information and the request view angle information of the requested live video.
In the embodiment of the invention, a node server directly acquires the requested view angle information of the requested live video from the video playing request; the manner in which the node server obtains the request time information of the requested live video may refer to the foregoing description, and is not described herein again.
S403, the node server inquires at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video.
In the embodiment of the invention, the video stream data stored in all the blocks in the at least one block are combined according to the playing time sequence to form the complete video stream data of the live video in each shooting view.
S404, the node server screens the at least one block to obtain a target block, wherein the target block comprises target video stream data of the live broadcast video, playing time information and shooting visual angle information of the target video stream data, the playing time information is matched with the request time information, and the shooting visual angle information is matched with the request visual angle information.
In this embodiment of the present invention, the matching between the playing time information of the target video stream data and the request time information may be: the start playing time indicated by the request time information is within the playing period indicated by the playing time information or earlier than the earliest time in the playing period. The matching of the shooting view information and the request view information of the target video stream data means: the photographing angle of view indicated by the photographing angle of view information coincides with the viewing angle of view indicated by the requested angle of view information.
S405, the node server sends the target video stream data in the target block to the client.
Correspondingly, the client receives target video stream data sent by the node server and plays live video based on the target video stream data.
In the embodiment of the invention, when a plurality of target blocks are obtained by screening, the node server can sequentially send the target video stream data in each target block to the client according to the sequence of the playing time indicated by the playing time information of the target video stream data in the plurality of target blocks, so that the problem that the video playing is not smooth as the client receives the video stream data with the playing time first can be avoided to a certain extent.
In an embodiment, the code rate of the target video stream data in the target block is a first code rate, before the node server sends the target video stream data in the target block to the client, state data for indicating the performance of a network channel between the node server and the client is obtained, and whether the state data meets a video code rate adjustment condition is detected; if the state data meets the video code rate adjustment condition, adjusting the code rate of the target video stream data in the target block from the first code rate to a second code rate; and then sending the target video stream data with the second code rate in the target block to the client.
In an embodiment, the status data includes a data packet loss rate and/or a data transmission delay. The node server sends test data to the client, wherein the test data can be at least one part of any target video stream data; after receiving the test data sent by the node server, the client measures the data packet loss rate of the received test data; and then feeding back the data packet loss rate as a congestion signal to the node server together with the timestamp. The node server obtains a packet loss rate of data fed back by the client, and measures data transmission delay by using a timestamp fed back by the client, where the data transmission delay may be a data round-trip delay. Further, the node server estimates the bandwidth of the network channel according to the data packet loss rate and/or the data transmission delay. The node server may estimate the bandwidth of the network channel by using a TCP (transmission control protocol) congestion or TFRC-like (friendly rate control) bandwidth estimation algorithm based on the data packet loss rate and/or the data transmission delay.
If the estimated bandwidth of the network channel is less than or equal to the bandwidth determined according to the first code rate, and the bandwidth determined according to the first code rate is greater than or equal to the first code rate, it indicates that the performance or the network state of the current network channel is not good and the transmission requirement of the target video stream data of the first code rate cannot be met; and the node server determines that the state data meets the video code rate adjustment condition, and adjusts the code rate of the target video stream data in the target block from the first code rate to a second code rate, wherein the second code rate is smaller than the first code rate.
It should be noted that, for an implementation manner that is not described in detail in each step in this embodiment, reference may be made to the related description in the first method embodiment, and this embodiment is not described again.
The embodiment of the invention inquires at least one block for storing the video stream data of the live video from the block chain network, screens out the target block with the playing time information matched with the request time information and the shooting visual angle information matched with the request visual angle information from the at least one block, and sends the target video stream data in the target block to the client, thereby realizing the transmission of the video stream data based on the block chain network and increasing the diversity of the video stream data transmission.
Referring to fig. 5, fig. 5 is a schematic structural diagram of a data processing apparatus based on a block chain according to an embodiment of the present invention. The data processing apparatus based on a blockchain described in the embodiment of the present invention is applied to the node server described above, and the apparatus includes:
an obtaining unit 501, configured to obtain request time information of a requested live video in response to a video playing request sent by a client, where the video playing request carries an identifier of the live video;
a processing unit 502, configured to query, according to the identifier of the live video, at least one tile for storing video stream data of the live video from a tile chain network;
the processing unit 502 is further configured to filter the at least one block to obtain a target block, where the target block includes target video stream data of the live video and playing time information of the target video stream data, and the playing time information is matched with the request time information;
a transceiving unit 503, configured to send target video stream data in the target tile to the client.
In an embodiment, the obtaining unit 501 is further configured to obtain request view angle information of a live video requested by a video playing request after obtaining request time information of the requested live video in response to the video playing request sent by a client;
the target block further comprises shooting visual angle information of the target video stream data, and the shooting visual angle information is matched with the request visual angle information.
In an embodiment, when the obtaining unit 501 responds to a video playing request sent by a client and obtains request time information of a requested live video, the obtaining unit is specifically configured to:
responding to a video playing request sent by a client, and acquiring request time information of the live video carried by the video playing request;
the request time information is used for indicating the start playing time of the requested live video, and the start playing time is earlier than the sending time of the video playing request.
In another embodiment, when the obtaining unit 501 responds to a video playing request sent by a client and obtains request time information of a requested live video, the obtaining unit is specifically configured to:
responding to a video playing request sent by a client, and acquiring the sending time or the receiving time of the video playing request;
and determining request time information of the requested live video according to the sending time or the receiving time, wherein the request time information is used for indicating the starting playing time of the requested live video.
In an embodiment, the video stream data stored in all of the at least one chunk are combined in a playing time order to form a complete video stream data of the live video.
In an embodiment, the number of the target tiles is multiple, and when the transceiver 503 sends the target video stream data in the target tiles to the client, the transceiver is specifically configured to:
and sequentially sending the target video stream data in each target block to the client according to the sequence of the playing time indicated by the playing time information of the target video stream data in the plurality of target blocks.
In an embodiment, the bitrate of the target video stream data in the target block is a first bitrate, and the processing unit 502 is further configured to:
acquiring state data for indicating the performance of a network channel between a server and the client, and detecting whether the state data meets video code rate adjustment conditions;
if the state data meet the video code rate adjustment condition, adjusting the code rate of target video stream data in the target block from a first code rate to a second code rate;
when the transceiving unit 503 sends the target video stream data in the target block to the client, it is specifically configured to:
and sending the target video stream data with the second code rate in the target block to the client.
In an embodiment, the state data includes a data packet loss rate and/or a data transmission delay, and when the processing unit 502 detects whether the state data satisfies a video code rate adjustment condition, the processing unit is specifically configured to:
estimating the bandwidth of the network channel according to the data packet loss rate and/or the data transmission delay;
if the bandwidth is smaller than or equal to the bandwidth determined according to the first code rate, determining that the state data meets the video code rate adjustment condition; wherein the second code rate is less than the first code rate.
It can be understood that the functions of each functional unit of the data processing apparatus based on the block chain according to the embodiment of the present invention may be specifically implemented according to the method in the foregoing method embodiment, and the specific implementation process may refer to the related description of the foregoing method embodiment, which is not described herein again.
The embodiment of the invention inquires at least one block for storing the video stream data of the live video from the block chain network, screens out the target block with the playing time information of the stored video stream data matched with the request time information from the at least one block, and sends the target video stream data in the target block to the client, thereby realizing the transmission of the video stream data based on the block chain network and increasing the diversity of the video stream data transmission.
Referring to fig. 6, fig. 6 is a schematic structural diagram of a server according to an embodiment of the present invention. The server described in the embodiment of the present invention includes: a processor 601, a communication interface 602, and a memory 603. The processor 601, the communication interface 602, and the memory 603 may be connected by a bus or other means, and the embodiment of the present invention is exemplified by being connected by a bus.
The processor 601 (or CPU) is a computing core and a control core of the server, and can analyze various instructions in the server and process various data of the server, for example: the CPU may transmit various types of interactive data between the internal structures of the server, and so on. The communication interface 602 may optionally include a standard wired interface, a wireless interface (e.g., Wi-Fi, mobile communication interface, etc.), controlled by the processor 601 for transceiving data. The Memory 603(Memory) is a Memory device in the server for storing programs and data. It is understood that the memory 603 herein may include both the built-in memory of the server and, of course, the expansion memory supported by the server. The memory 603 provides storage space that stores the operating system of the server, which may include, but is not limited to: android system, iOS system, Windows Phone system, etc., which are not limited in this respect.
In the embodiment of the present invention, the processor 601 executes the executable program code in the memory 603 to perform the following operations:
responding to a video playing request sent by a client, and acquiring request time information of a requested live video, wherein the video playing request carries an identifier of the live video; inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video; screening the at least one block to obtain a target block, wherein the target block comprises target video stream data of the live broadcast video and playing time information of the target video stream data, and the playing time information is matched with the request time information; the target video stream data in the target tile is sent to the client through the communication interface 602.
In an embodiment, after the processor 601, in response to a video playing request sent by a client, acquires request time information of a requested live video, the processor is further configured to: acquiring request view angle information of a live video requested by the video playing request; the target block further comprises shooting visual angle information of the target video stream data, and the shooting visual angle information is matched with the request visual angle information.
In an embodiment, when the processor 601 responds to a video playing request sent by a client and acquires request time information of a requested live video, the processor is specifically configured to: responding to a video playing request sent by a client, and acquiring request time information of the live video carried by the video playing request; the request time information is used for indicating the start playing time of the requested live video, and the start playing time is earlier than the sending time of the video playing request.
In another embodiment, when the processor 601 responds to a video playing request sent by a client and acquires request time information of a requested live video, the processor is specifically configured to: responding to a video playing request sent by a client, and acquiring the sending time or the receiving time of the video playing request; and determining request time information of the requested live video according to the sending time or the receiving time, wherein the request time information is used for indicating the starting playing time of the requested live video.
In an embodiment, the video stream data stored in all of the at least one chunk are combined in a playing time order to form a complete video stream data of the live video.
In an embodiment, the number of the target tiles is multiple, and when the processor 601 sends the target video stream data in the target tiles to the client through the communication interface 602, the processor is specifically configured to:
and sequentially sending the target video stream data in each target block to the client through the communication interface 602 according to the sequence of the playing time indicated by the playing time information of the target video stream data in the target blocks.
In an embodiment, the bitrate of the target video stream data in the target chunk is a first bitrate, and before the processor 601 sends the target video stream data in the target chunk to the client through the communication interface 602, the processor is further configured to: acquiring state data for indicating the performance of a network channel between a server and the client, and detecting whether the state data meets video code rate adjustment conditions; if the state data meet the video code rate adjustment condition, adjusting the code rate of target video stream data in the target block from a first code rate to a second code rate;
when the processor 601 sends the target video stream data in the target block to the client through the communication interface 602, the processor is specifically configured to:
and sending the target video stream data with the second bitrate in the target block to the client through a communication interface 602.
In an embodiment, the state data includes a data packet loss rate and/or a data transmission delay, and when the processor 601 detects whether the state data satisfies a video bitrate adjustment condition, the processor is specifically configured to: estimating the bandwidth of the network channel according to the data packet loss rate and/or the data transmission delay; if the bandwidth is smaller than or equal to the bandwidth determined according to the first code rate, determining that the state data meets the video code rate adjustment condition; wherein the second code rate is less than the first code rate.
In a specific implementation, the processor 601, the communication interface 602, and the memory 603 described in this embodiment of the present invention may execute an implementation manner of a server described in a data processing method based on a block chain provided in this embodiment of the present invention, and may also execute an implementation manner described in a data processing apparatus based on a block chain provided in this embodiment of the present invention, which is not described herein again.
The embodiment of the invention inquires at least one block for storing the video stream data of the live video from the block chain network, screens out the target block with the playing time information of the stored video stream data matched with the request time information from the at least one block, and sends the target video stream data in the target block to the client, thereby realizing the transmission of the video stream data based on the block chain network and increasing the diversity of the video stream data transmission.
The embodiment of the present invention further provides a storage medium, where instructions are stored in the storage medium, and when the storage medium runs on a computer, the storage medium causes the computer to execute the data processing method based on the blockchain according to the embodiment of the present invention.
Embodiments of the present invention further provide a computer program product including instructions, which when run on a computer, cause the computer to execute the data processing method based on a block chain according to the embodiments of the present invention.
It should be noted that, for simplicity of description, the above-mentioned embodiments of the method are described as a series of acts or combinations, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required by the invention.
Those skilled in the art will appreciate that all or part of the steps in the methods of the above embodiments may be implemented by associated hardware instructed by a program, which may be stored in a computer-readable storage medium, and the storage medium may include: flash disks, Read-Only memories (ROMs), Random Access Memories (RAMs), magnetic or optical disks, and the like.
The above disclosure is intended to be illustrative of only some embodiments of the invention, and is not intended to limit the scope of the invention.

Claims (9)

1. A method for processing data based on a blockchain, the method comprising:
responding to a video playing request sent by a client, and acquiring request time information and request visual angle information of a requested live video, wherein the video playing request carries an identifier of the live video;
inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video, wherein the video stream data stored in all the blocks in the at least one block are combined according to a playing time sequence to form complete video stream data of the live video;
screening the at least one block to obtain a target block, wherein the target block comprises target video stream data of the live broadcast video, playing time information and shooting visual angle information of the target video stream data, the playing time information is matched with the request time information, and the shooting visual angle information is matched with the request visual angle information;
and sending the target video stream data in the target block to the client.
2. The method of claim 1, wherein the obtaining request time information of the requested live video in response to a video playing request sent by a client comprises:
responding to a video playing request sent by a client, and acquiring request time information of the live video carried by the video playing request;
the request time information is used for indicating the start playing time of the requested live video, and the start playing time is earlier than the sending time of the video playing request.
3. The method of claim 1, wherein the obtaining request time information of the requested live video in response to a video playing request sent by a client comprises:
responding to a video playing request sent by a client, and acquiring the sending time or the receiving time of the video playing request;
and determining request time information of the requested live video according to the sending time or the receiving time, wherein the request time information is used for indicating the starting playing time of the requested live video.
4. The method of any one of claims 1-3, wherein the target tile is plural, and wherein sending the target video stream data in the target tile to the client comprises:
and sequentially sending the target video stream data in each target block to the client according to the sequence of the playing time indicated by the playing time information of the target video stream data in the plurality of target blocks.
5. The method of claim 1, wherein the bitrate of the target video stream data in the target chunk is a first bitrate, and before sending the target video stream data in the target chunk to the client, the method further comprises:
acquiring state data for indicating the performance of a network channel between a server and the client, and detecting whether the state data meets video code rate adjustment conditions;
if the state data meet the video code rate adjustment condition, adjusting the code rate of target video stream data in the target block from a first code rate to a second code rate;
the sending the target video stream data in the target block to the client comprises:
and sending the target video stream data with the second code rate in the target block to the client.
6. The method of claim 5, wherein the status data includes a data packet loss rate and/or a data transmission delay, and the detecting whether the status data satisfies a video bitrate adjustment condition comprises:
estimating the bandwidth of the network channel according to the data packet loss rate and/or the data transmission delay;
if the bandwidth is smaller than or equal to the bandwidth determined according to the first code rate, determining that the state data meets the video code rate adjustment condition;
wherein the second code rate is less than the first code rate.
7. A blockchain-based data processing apparatus, the apparatus comprising:
the system comprises an acquisition unit, a video playing unit and a video playing unit, wherein the acquisition unit is used for responding to a video playing request sent by a client, and acquiring request time information and request visual angle information of a requested live video, and the video playing request carries an identifier of the live video;
the processing unit is used for inquiring at least one block for storing video stream data of the live video from a block chain network according to the identification of the live video, and the video stream data stored in all the blocks in the at least one block are combined according to a playing time sequence to form complete video stream data of the live video;
the processing unit is further configured to filter the at least one block to obtain a target block, where the target block includes target video stream data of the live video, and play time information and shooting view angle information of the target video stream data, the play time information is matched with the request time information, and the shooting view angle information is matched with the request view angle information;
and the transceiving unit is used for sending the target video stream data in the target block to the client.
8. A server, comprising: a processor, a communication interface and a memory, which are connected to each other, wherein the memory stores executable program code, and the processor is configured to call the executable program code to execute the block chain based data processing method according to any one of claims 1 to 6.
9. A storage medium having stored therein instructions which, when run on a computer, cause the computer to execute the method of block chain based data processing according to any one of claims 1 to 6.
CN201910869594.2A 2019-09-16 2019-09-16 Data processing method based on block chain, server and storage medium Active CN110602515B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910869594.2A CN110602515B (en) 2019-09-16 2019-09-16 Data processing method based on block chain, server and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910869594.2A CN110602515B (en) 2019-09-16 2019-09-16 Data processing method based on block chain, server and storage medium

Publications (2)

Publication Number Publication Date
CN110602515A CN110602515A (en) 2019-12-20
CN110602515B true CN110602515B (en) 2021-08-10

Family

ID=68859644

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910869594.2A Active CN110602515B (en) 2019-09-16 2019-09-16 Data processing method based on block chain, server and storage medium

Country Status (1)

Country Link
CN (1) CN110602515B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114679604B (en) * 2022-04-11 2023-12-19 上海哔哩哔哩科技有限公司 Resource processing method and device
CN115209175B (en) * 2022-07-18 2023-10-24 深圳蓝色鲨鱼科技有限公司 Voice transmission method and system

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108156467A (en) * 2017-11-16 2018-06-12 腾讯科技(成都)有限公司 Data transmission method and device, storage medium and electronic device
CN110012300A (en) * 2018-01-04 2019-07-12 华为技术有限公司 Net cast method and device

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5014244B2 (en) * 2008-05-02 2012-08-29 キヤノン株式会社 VIDEO DISTRIBUTION DEVICE, ITS CONTROL METHOD, VIDEO DISTRIBUTION SYSTEM, AND PROGRAM
CN110348242B (en) * 2017-06-12 2021-01-15 腾讯科技(深圳)有限公司 Service request processing method and device
CN109040227B (en) * 2018-07-27 2021-08-03 江西贪玩信息技术有限公司 Service request response method and device based on block chain and computer equipment

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108156467A (en) * 2017-11-16 2018-06-12 腾讯科技(成都)有限公司 Data transmission method and device, storage medium and electronic device
CN110012300A (en) * 2018-01-04 2019-07-12 华为技术有限公司 Net cast method and device

Also Published As

Publication number Publication date
CN110602515A (en) 2019-12-20

Similar Documents

Publication Publication Date Title
US7941123B2 (en) Method and system for downloading data to mobile terminals and for implementing data sharing between mobile terminals
CN100556129C (en) A kind of equity connects flow medium live system and device
CN101146110B (en) A method for playing stream media
KR101882347B1 (en) block chain-based decentralized contents distribution system for IP network and method for the same
US8726327B2 (en) System and method for peer-to-peer live streaming
US20110055881A1 (en) Media file on-demand method, system and appartus
CN108681943A (en) A kind of data processing method, device, equipment and the storage medium of block chain network
US20150312296A1 (en) Method and device for pushing multimedia resource and display terminal
CN112714192B (en) Data synchronization method and device, computer readable medium and electronic equipment
CN108063769B (en) Method and device for realizing content service and content distribution network node
CN108881931B (en) Data buffering method and network equipment
CN110602515B (en) Data processing method based on block chain, server and storage medium
US20110082943A1 (en) P2p network system and data transmitting and receiving method thereof
WO2011088725A1 (en) Method and apparatus for synchronization based on hypertext transfer protocol (http)
CN105871800A (en) Pull stream control method, device and system
WO2018233539A1 (en) Video processing method, computer storage medium, and device
CN112040259A (en) Method, server, system, storage medium and equipment for continuous playing
CN110677714A (en) Video data downloading method and device, electronic equipment and storage medium
CN110445723A (en) A kind of network data dispatching method and fringe node
US20090222890A1 (en) Method and apparatus for providing streaming service based on p2p and streaming service system using the same
WO2023061060A1 (en) Audio and video code stream scheduling method, system, medium and electronic apparatus
CN109561137A (en) Establish method, apparatus, terminal device and the medium of P2P network
CN107959704B (en) Data processing method and home gateway
US20120246332A1 (en) Circular buffer and method for multimedia streaming service based peer-to-peer
CN109510868A (en) A kind of method, apparatus that establishing P2P network, terminal device and storage medium

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