CN101262360A - A method and device for real time stream media multi-point transmission - Google Patents
A method and device for real time stream media multi-point transmission Download PDFInfo
- Publication number
- CN101262360A CN101262360A CNA2008100896589A CN200810089658A CN101262360A CN 101262360 A CN101262360 A CN 101262360A CN A2008100896589 A CNA2008100896589 A CN A2008100896589A CN 200810089658 A CN200810089658 A CN 200810089658A CN 101262360 A CN101262360 A CN 101262360A
- Authority
- CN
- China
- Prior art keywords
- node
- group
- server
- data
- transmission
- 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.)
- Pending
Links
Images
Landscapes
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The invention discloses a method for the real-time multipoint transmission of streaming media and equipment thereof. A server is utilized to divide nodes into more than one group and each group forms a binary tree; the data of program contents to be transmitted are divided for being distributed to each group and the server respectively transmits the data of each group to root nodes of each binary tree. The method of the invention causes the nodes to transmit data to each other, greatly lowers the outage probability during broadcasting and enhances broadcasting stability; meanwhile, the method can be simply realized, can not only avoid single point failure of each node, but also have highly efficient transmission, guarantee completeness during transmission process and adapt to various network environments.
Description
Technical field
The present invention relates to the internet data transmission technology, be meant a kind of real time flow medium point transmitting method and equipment especially based on peer-to-peer network interconnected (P2P, Peer to Peer) pattern.
Background technology
Along with popularizing of broadband and developing rapidly of communication network technology, the network multimedia service obtains wide application.But a large amount of appearance of Streaming Media, bandwidth and performance to the server end network have proposed requirements at the higher level, for example, a bit rate is the video frequency program of 300kbps, if 1000 people visit is arranged simultaneously, the server end network bandwidth must reach more than the 300Mbps so, if will support that more user data is exactly extremely difficult this moment.Because Streaming Media is very big to the resource requirement of flow bandwidth, settlement server end flow bandwidth bottleneck becomes the major issue that promotes the Streaming Media application development.
Interconnected (the P2P of peer-to-peer network, Peer to Peer) technology has changed traditional the Internet operational mode, it has broken through traditional customer end/server mode, emphasize " equity " between the node, each node has two kinds of identity of server and client side concurrently, also provides service for other nodes when utilizing the resource of other nodes.Each node main frame be server be again client computer, mutual shared resource can conserve bandwidth, the service ability of whole system increases along with the increase of number of users, transfer of data is a topmost content in the P2P technology.
But the method for transfer of data is comparatively complicated in the prior art, causes transmitting speed slower, and how a kind of effectively easy data transmission method is provided, and is problem demanding prompt solution in the P2P stream media technology.
Summary of the invention
In view of this, the present invention proposes a kind of method and apparatus of simple real time flow medium multicast communication, improves the Streaming Media transmission speed.
Based on the method for above-mentioned purpose a kind of real time flow medium multicast communication provided by the invention, utilize server that node is divided into more than one group, form a binary tree for every group;
Program content data waiting for transmission is cut apart to distribute to each group, and server is respectively organized data to the root node transmission of each binary tree respectively.
The step that this method cuts apart program content data waiting for transmission to distribute to each group comprises: programme content waiting for transmission is divided into a plurality of data blocks according to fixed size or packet, distributes to each group.
The described server of this method is respectively organized data to the root node transmission of each binary tree respectively and comprised: data block i*8+k correspondence is passed to group k, i=0, and 1,2,3 ... k=0,1 ... n-1, wherein n is the group number.
Described each the initiate node of this method all is assigned to the minimum group of interstitial content at every turn.
This method is preserved channel list and node listing at server end; Comprise the channel ID that server has in the channel list, corresponding n the node listing of each channel; Comprise the nodal information that connects each channel in the node listing.
The described nodal information of this method comprises: node ID, father node ID, child node ID, the group number of all nodes in the node number in every group, the group number of this group, the group.
This method also comprises the step that node adds: new node is initiated the linking request with server, server-assignment returns channel list for he node number ID, node is selected channel, the node listing of this channel of server search, minimum one group of the node that therefrom select to connect, this node ID is registered in the node listing of this group, insert group number, from the node of this group, select the father node of the node of a weights minimum as new node, in node listing, revise corresponding, the node of a weights minimum of every group selection from each is organized in addition, the nodal information of selected node is issued this new node, new node is connected with these points respectively, after definite connection is gone up, receives the data of each group from these nodes.
The described node of this method receives in the data procedures and also comprises: node judges regularly whether network condition meets the requirements, if undesirable, then the Connection Service device looks for new node to connect; If meet the requirements then continue to receive data, be kept at this locality from each node.
The described weights of this method are weighted values of the distance of child node number and this node and server
The described server of this method and all nodes are kept in touch in the heartbeat mode, the every certain interval of time of node sends the message of my existence of expression to server, if the continuous pre-determined number of server does not all receive the message that this node is sent out, judge that then this node withdraws from.
This method is after node withdraws from, the information of this node of his father's knot removal, interior this nodal information of interior this father node of node listing is also deleted in the server, the child node below this node and the child node of child node begin upwards to seek from level to level new father node from root node all, revise the relevant information on its nodal information and the server; If this node is being given another node transmission data, then server selects a node to these another node transmission data to this another node in addition.
This method also comprises node broadcast implementation procedure: each node is opened the internal memory store data, and the data block of receiving is put into corresponding memory address, after being filled with, puts into player plays, then the data of having play is emptied; Do not receive if find certain blocks of data when putting into player, directly send out request, ask for this blocks of data to server.
The Thread Count that described group of number of this method equals to preset, if the node number that is connected to server less than default Thread Count, each node all is connected with server; If the node number that is connected to server greater than, node is opened all threads.
Described group of number of this method is 8.
The present invention also provides a kind of equipment of realizing the real time flow medium multicast communication, and it is configured for the aforesaid method that realizes.
From above as can be seen, use the method and apparatus of real time flow medium multicast communication of the present invention to transmit data from n point simultaneously, improved network transfer speeds greatly, solved the shortcoming of unicast, when a node that data are provided withdraws from, system seeks new node automatically and transmits data, at this moment, have only n/one data to transmit from new node, the data of all the other n-1/n still from original node transmission, do not change, significantly reduced the situation of data variation, the broadcast interrupt probability is reduced greatly, increased the stability of playing, this method realizes simple simultaneously, both avoided the Single Point of Faliure problem of each node, have efficiency of transmission efficiently simultaneously, can guarantee the integrality in the transmission course, and can adapt to variety of network environments.
Description of drawings
Fig. 1 is an embodiment of the invention node grouping topological structure schematic diagram;
Fig. 2 adds the schematic flow sheet of step for embodiment of the invention node;
Fig. 3 be in the embodiment of the invention data multicast communication process node to the judgment processing schematic flow sheet of network condition;
Fig. 4 plays the schematic flow sheet of implementation procedure for embodiment of the invention node.
Embodiment
With reference to the accompanying drawings the present invention is described more fully, exemplary embodiment of the present invention wherein is described.
The present invention provides a kind of real time flow medium point transmitting method based on the P2P pattern in order to address the above problem.Utilize server that node is divided into more than one group, form a binary tree for every group; Program content data waiting for transmission is cut apart to distribute to each group, and server is respectively organized data to the root node transmission of each binary tree respectively.Further also can be with the programme content piecemeal, server is respectively organized data to the root node transmission of each tree respectively, preserves channel list and node listing at server end, mutual data transmission between the node.Thereby make that playing interrupt probability reduces greatly, has increased the stability of playing.
Referring to shown in Figure 1, present embodiment at first utilizes server that node is divided into 8 groups, form 8 binary trees, each initiate node all is assigned to the minimum group of interstitial content at every turn, programme content is according to fixed size or packet piecemeal, and each program data piece distributes a unique sequence number, like this, server is respectively organized data to the root node transmission of each tree respectively, that is:
Data block 0,8,16 ... correspondence is passed to group 0;
Data block 2,10,18 ... correspondence is passed to group 2;
Data block 3,11,19 ... correspondence is passed to group 3;
Data block 4,12,20 ... correspondence is passed to group 4;
Data block 5,13,21 ... correspondence is passed to group 5;
Data block 6,14,22 ... correspondence is passed to group 6;
Data block 7,15,23 ... correspondence is passed to group 7;
Data block i*8+k...... correspondence is passed to group k, i=0 in the present embodiment, and 1,2,3 ...; K=0,1 ..., 7.
According to said method, the step of specific implementation transfer of data is as follows:
Preserve channel list and node listing at server end in advance.
Wherein, channel list, the channel ID that the expression server has, corresponding 8 node listings of each channel, the corresponding groups of nodes of each node listing;
Node listing, each nodal information that connects certain channel all is kept in the node listing, and nodal information comprises (information that node stores above):
(1) every group of interior node number;
(2) group number of this group;
(3) all nodes that group is interior are listd under each node has: node ID, father node ID, child node ID, group number.Wherein which group is group number represent this node in, and node has 8 node listings, and the 0th node listing put the 0th group node, initiate a connection at the 0th node listing, require the data of the 0th group of transmission, the other side begins to transmit this group data, and the rest may be inferred for other node listings.
Referring to shown in Figure 2, the step that node adds comprises:
Above-mentioned weights are calculated values, are the distance weighted values of jumping figure one by one of child node number and this node and server.
Referring to shown in Figure 3, step 301~302, this moment, node A was connected with 8 nodes, whether node A judges regularly whether network condition meets the requirements, such as keeping and being connected of each node, if undesirable, disconnect such as certain node, then execution in step 303, and the Connection Service device looks for new node to connect.If meet the requirements then execution in step 304 from 8 nodes transmission data, be kept in the local data table.
In practical operation, the situation that node withdraws from can occur, be divided into normally withdrawing from and withdraw from: normally withdraw from being certain node stop and watching program, log off with improper; Improper withdrawing from is to withdraw from because network condition is bad.The method whether the differentiation node withdraws from is as follows:
Server and all nodes are kept in touch in the heartbeat mode, and node was told server to message of server transmission " I exist " in per 10 seconds, and this node exists, if continuous 3 times all do not receive the message that node A sends out, thinks that then this node withdraws from.
Node withdraws from the back interdependent node and revises information, and the step of carrying out the data multicast communication is as follows:
Node A withdraws from, the information that his father's Node B is preserved is revised, delete the information of this child node, interior this father node B neutron nodal information A of node listing also deletes in the server, the child node below the node A and the child node of child node begin upwards to look for again from level to level new father node from root node all, (the information that comprises child node A of deletion of node B in the node listing of server, all child nodes for node A, give them a new father node by server-assignment) revise the relevant information on its nodal information and the server, if node A is giving node C transmission data, then server is selected a node D in addition to node C, transmits data by node D to node C.
Referring to shown in Figure 4, it is as follows that the node of the embodiment of the invention is play implementation procedure:
Step 401, each node are opened up certain region of memory as the tables of data store data, establish and can deposit 1024 blocks of data, open 8 and connect the reception data; Verify in the tables of data whether the data block of flog=0 is arranged earlier, if enter step 402, otherwise, return step 401.
Step 402 receives data from other nodes, leaves in the tables of data, is specially data block number and 1024 deliverys that will receive, puts into corresponding memory address according to remainder.
Step 403~404 judge whether to receive the data that need broadcast, if can enter step 405, otherwise directly send out request to server, obtain data from server and put into tables of data.
Step 405~406 are put into the broadcast buffer memory to the data in the tables of data, play.
In the preferred embodiment of the present invention, the above-mentioned steps execution that circulates in playing process after tables of data is filled with, is put into and is play buffer memory and play, and then the data of having play in the tables of data is emptied, and returns step 401.
Under special circumstances, it might be to be less than 8 nodes to link server that node adds fashionable, and then each node all is connected with server; Single thread is then directly obtained total data from server; Since the 9th node, node is opened 8 threads, obtains data respectively from 8 nodes of front.Wherein said Thread Count is corresponding with the group number, i.e. corresponding group of thread, and first thread of described node is corresponding to first group node, and second thread be corresponding to second group node, all the other and the like.
According to the above embodiment of the present invention, can improve network transfer speeds greatly simultaneously from 8 some transmission data, solved the shortcoming of unicast.When a node that data are provided withdraws from, system seeks new node automatically and transmits data, at this moment, have only eighth data to transmit from new node, all the other data of 7/8ths still from original node transmission, do not change, and have significantly reduced the situation of data variation, the broadcast interrupt probability is reduced greatly, increased the stability of playing.The inventive method realizes simply both having avoided the Single Point of Faliure problem of each node simultaneously, has efficiency of transmission efficiently simultaneously, can guarantee the integrality in the transmission course, and can adapt to variety of network environments.
Be example to be 8 groups with node division among the above embodiment, those skilled in the art are readily appreciated that, the node grouping number n also can be got other arbitrarily greater than 1 integer.
Based on said method, the present invention also provides a kind of equipment of realizing the real time flow medium multicast communication, and this equipment can exist with the form of above-mentioned server, has the function of above-mentioned server, and node is divided into more than one group, forms a binary tree for every group; Program content data waiting for transmission is cut apart distributing to each group, and respectively organized data to the transmission of the root node of each binary tree respectively.
Description of the invention is in order to provide for the purpose of example and the explanation, and is not exhaustively or limit the invention to disclosed form.Many modifications and variations are obvious for the ordinary skill in the art.Selecting and describing embodiment is for better explanation principle of the present invention and practical application, thereby and makes those of ordinary skill in the art can understand the various embodiment that have various modifications that the present invention's design is suitable for special-purpose.
Claims (15)
1. the method for a real time flow medium multicast communication is characterized in that, utilizes server that node is divided into more than one group, forms a binary tree for every group;
Program content data waiting for transmission is cut apart to distribute to each group, and server is respectively organized data to the root node transmission of each binary tree respectively.
2. method according to claim 1 is characterized in that, the step that program content data waiting for transmission is cut apart to distribute to each group comprises: programme content waiting for transmission is divided into a plurality of data blocks according to fixed size or packet, distributes to each group.
3. method according to claim 2 is characterized in that, described server is respectively organized data to the root node transmission of each binary tree respectively and comprised: data block i*8+k correspondence is passed to group k, i=0, and 1,2,3 ... k=0,1 ... n-1, wherein n is the group number.
4. method according to claim 1 is characterized in that, described each initiate node all is assigned to the minimum group of interstitial content at every turn.
5. according to any described method of claim 1 to 4, it is characterized in that, preserve channel list and node listing at server end; Comprise the channel ID that server has in the channel list, corresponding n the node listing of each channel; Comprise the nodal information that connects each channel in the node listing.
6. method according to claim 5 is characterized in that, described nodal information comprises: node ID, father node ID, child node ID, the group number of all nodes in the node number in every group, the group number of this group, the group.
7. method according to claim 6, it is characterized in that, this method also comprises the step that node adds: new node is initiated the linking request with server, server-assignment returns channel list for he node number ID, node is selected channel, the node listing of this channel of server search, minimum one group of the node that therefrom select to connect, this node ID is registered in the node listing of this group, insert group number, from the node of this group, select the father node of the node of a weights minimum, in node listing, revise corresponding, the node of a weights minimum of every group selection from other each group as new node, the nodal information of selected node is issued this new node, new node is connected with these points respectively, after definite connection is gone up, receives the data of each group from these nodes.
8. method according to claim 7 is characterized in that, described node receives in the data procedures and also comprises: node judges regularly whether network condition meets the requirements, if undesirable, then the Connection Service device looks for new node to connect; If meet the requirements then continue to receive data, be kept at this locality from each node.
9. method according to claim 7 is characterized in that, described weights are weighted values of the distance of child node number and this node and server.
10. method according to claim 1, it is characterized in that, described server and all nodes are kept in touch in the heartbeat mode, the every certain interval of time of node sends the message of my existence of expression to server, if the continuous pre-determined number of server does not all receive the message that this node is sent out, judge that then this node withdraws from.
11. method according to claim 10, it is characterized in that, after node withdraws from, the information of this node of his father's knot removal, interior this nodal information of interior this father node of node listing is also deleted in the server, the child node below this node and the child node of child node begin upwards to seek from level to level new father node from root node all, revise the relevant information on its nodal information and the server; If this node is being given another node transmission data, then server selects a node to these another node transmission data to this another node in addition.
12. method according to claim 1 is characterized in that, this method also comprises node broadcast implementation procedure: each node is opened the internal memory store data, the data block of receiving is put into corresponding memory address, after being filled with, put into player plays, then the data of having play are emptied; Do not receive if find certain blocks of data when putting into player, directly send out request, ask for this blocks of data to server.
13. method according to claim 1 is characterized in that, the described group of Thread Count that number equals to preset, if the node number that is connected to server less than default Thread Count, each node all is connected with server; If the node number that is connected to server greater than, node is opened all threads.
14., it is characterized in that described group of number is 8 according to claim 1 to 4,10 to 13 any described methods.
15. an equipment of realizing the real time flow medium multicast communication is characterized in that, it is configured for realizes as the described method of claim 1-14.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNA2008100896589A CN101262360A (en) | 2008-04-11 | 2008-04-11 | A method and device for real time stream media multi-point transmission |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNA2008100896589A CN101262360A (en) | 2008-04-11 | 2008-04-11 | A method and device for real time stream media multi-point transmission |
Publications (1)
Publication Number | Publication Date |
---|---|
CN101262360A true CN101262360A (en) | 2008-09-10 |
Family
ID=39962586
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CNA2008100896589A Pending CN101262360A (en) | 2008-04-11 | 2008-04-11 | A method and device for real time stream media multi-point transmission |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101262360A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102238429A (en) * | 2010-04-27 | 2011-11-09 | 宏碁股份有限公司 | Channel scheduling method for mobile television network |
CN101668037B (en) * | 2009-09-29 | 2012-07-25 | 乐视网信息技术(北京)股份有限公司 | Method for dispatching P2P network |
CN102273167B (en) * | 2008-12-30 | 2014-11-26 | 意大利电信股份公司 | Method and system for data management in peer-to- peer network |
CN106612454A (en) * | 2015-10-23 | 2017-05-03 | 北京国双科技有限公司 | Video cache processing method and device |
-
2008
- 2008-04-11 CN CNA2008100896589A patent/CN101262360A/en active Pending
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102273167B (en) * | 2008-12-30 | 2014-11-26 | 意大利电信股份公司 | Method and system for data management in peer-to- peer network |
CN101668037B (en) * | 2009-09-29 | 2012-07-25 | 乐视网信息技术(北京)股份有限公司 | Method for dispatching P2P network |
CN102238429A (en) * | 2010-04-27 | 2011-11-09 | 宏碁股份有限公司 | Channel scheduling method for mobile television network |
CN102238429B (en) * | 2010-04-27 | 2013-05-22 | 宏碁股份有限公司 | Channel scheduling method for mobile television network |
CN106612454A (en) * | 2015-10-23 | 2017-05-03 | 北京国双科技有限公司 | Video cache processing method and device |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN100405795C (en) | Service system for distributed reciprocal flow media and realizing method for requesting programm | |
CN100556129C (en) | A kind of equity connects flow medium live system and device | |
CN103731451B (en) | A kind of method and system that file uploads | |
CN101534205B (en) | Application layer multicast service realizing method, terminal and system thereof | |
Cao et al. | Datacast: A scalable and efficient reliable group data delivery service for data centers | |
CN101141459A (en) | Method of implementing data transmission or stream media transmission using combination of HTTP and P2P | |
CN103634692A (en) | CDN (content distribution network) and P2P (peer-to-peer) based hybrid stream media video-on-demand system | |
CN101945129A (en) | P2P (Peer to Peer) stream media live-broadcast low-delay transmission method and system thereof | |
CN102394899B (en) | On-demand system and method for improving file downloading speed | |
CN106059936B (en) | The method and device of cloud system Multicast File | |
CN101895576A (en) | P2P distributed streaming media live broadcast method with small-startup time delay | |
CN101626389A (en) | Network node management method | |
CN101304385A (en) | Method for improving large-scale equity network flow medium system | |
CN101262360A (en) | A method and device for real time stream media multi-point transmission | |
CN101459678B (en) | Fusion implementation method for digital media ordering and digital resource downloading | |
CN104822084A (en) | Concurrent-stream-based rapid channel switching method of P2P real-time playing system | |
EP3902279A1 (en) | Audio and video stream distribution method in audio and video stream distribution system, and dynamic parent node | |
CN101094387A (en) | Control system and method for transferring content on network | |
CN201766618U (en) | Network on-demand playing system | |
CN108419097A (en) | Video sharing method based on clustering tree under a kind of mobile ad hoc network | |
CN202261376U (en) | Cloud streaming media data transmission system | |
CN101197691A (en) | Method, system, login server and client terminal for implementing network advertisement | |
CN102821316A (en) | Improved video on demand (VOD) transmission method based on peer-to-peer computing core algorithm | |
CN103701827A (en) | Method for realizing stream media play based on self-adaption stream media service gateway system | |
CN101090367A (en) | Data transmission method and device in reciprocal network |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C12 | Rejection of a patent application after its publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20080910 |