[go: up one dir, main page]

WO2009140868A1 - 一种基于p2p的媒体播放方法、装置和系统 - Google Patents

一种基于p2p的媒体播放方法、装置和系统 Download PDF

Info

Publication number
WO2009140868A1
WO2009140868A1 PCT/CN2009/070375 CN2009070375W WO2009140868A1 WO 2009140868 A1 WO2009140868 A1 WO 2009140868A1 CN 2009070375 W CN2009070375 W CN 2009070375W WO 2009140868 A1 WO2009140868 A1 WO 2009140868A1
Authority
WO
WIPO (PCT)
Prior art keywords
node
content
demand
service
live
Prior art date
Application number
PCT/CN2009/070375
Other languages
English (en)
French (fr)
Inventor
戴芬
王铁英
严哲峰
Original Assignee
华为技术有限公司
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
Family has litigation
First worldwide family litigation filed litigation Critical https://patents.darts-ip.com/?family=41339753&utm_source=google_patent&utm_medium=platform_link&utm_campaign=public_patent_search&patent=WO2009140868(A1) "Global patent litigation dataset” by Darts-ip is licensed under a Creative Commons Attribution 4.0 International License.
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP09749411.6A priority Critical patent/EP2288085B1/en
Publication of WO2009140868A1 publication Critical patent/WO2009140868A1/zh
Priority to US12/950,778 priority patent/US9497035B2/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/02Details
    • H04L12/16Arrangements for providing special services to substations
    • H04L12/18Arrangements for providing special services to substations for broadcast or conference, e.g. multicast
    • H04L12/1813Arrangements for providing special services to substations for broadcast or conference, e.g. multicast for computer conferences, e.g. chat rooms
    • H04L12/1827Network arrangements for conference optimisation or adaptation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/60Network streaming of media packets
    • H04L65/61Network streaming of media packets for supporting one-way streaming services, e.g. Internet radio
    • H04L65/612Network streaming of media packets for supporting one-way streaming services, e.g. Internet radio for unicast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/80Responding to QoS
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/104Peer-to-peer [P2P] networks
    • H04L67/1074Peer-to-peer [P2P] networks for supporting data block transmission mechanisms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/433Content storage operation, e.g. storage operation in response to a pause request, caching operations
    • H04N21/4331Caching operations, e.g. of an advertisement for later insertion during playback
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/60Network structure or processes for video distribution between server and client or between remote clients; Control signalling between clients, server and network components; Transmission of management data between server and client, e.g. sending from server to client commands for recording incoming content stream; Communication details between server and client 
    • H04N21/63Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing
    • H04N21/632Control signaling related to video distribution between client, server and network components; Network processes for video distribution between server and clients or between remote clients, e.g. transmitting basic layer and enhancement layers over different transmission paths, setting up a peer-to-peer communication via Internet between remote STB's; Communication protocols; Addressing using a connection between clients on a wide area network, e.g. setting up a peer-to-peer communication via Internet for retrieving video segments from the hard-disk of other client devices
    • 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/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/472End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
    • H04N21/47202End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content for requesting content on demand, e.g. video on demand

Definitions

  • the present invention relates to the field of multimedia transmission, and in particular, to a P2P-based media playback method, apparatus and system.
  • P2P is a peer-to-peer computing or peer-to-peer network. Nodes share resources and services through direct exchange. Each node can be either a server or a client.
  • P2P-based video services include both live and on-demand.
  • Video live broadcast means that the program is played regularly by the server, and the user watches the program at the terminal, just like the play mode of the television.
  • the topology structure has the following characteristics: The server-centric topology is built. Each live edge server manages a part of the program, interacts with the Peer (node), provides program data buffering, and is responsible for inserting the newly added node into a certain location of the topology.
  • Video on demand is a service that provides interactive video services whenever the user needs it.
  • the topology structure has the following features: A server-centric on-demand topology structure can be implemented in the form of a mesh or a tree, and a SN (Super Node) is used as a backbone network. Each SN is responsible for managing one. The zone, interacting with the peer, provides a list of nodes that can be connected.
  • a peer-to-peer P2P-based media playback method includes the following steps:
  • the cached corresponding data streams are respectively provided to the on-demand node or the live broadcast node as data sources of the on-demand service or the live broadcast service.
  • an embodiment of the present invention further provides a node, including:
  • Login module used to log in to the network
  • a mode selection module configured to select a live broadcast service or an on-demand service
  • an information obtaining module configured to receive network information required for the live broadcast service or the on-demand service selected by the mode selection module, and determine whether to cache the data flow corresponding to the live broadcast service or the on-demand service;
  • a storage module configured to acquire the data flow according to the selection result of the mode selection module, and cache the data flow according to the determination result obtained by the information acquisition module.
  • an embodiment of the present invention further provides a user request routing system RRS, including:
  • a user management module configured to manage node information
  • a topology management module configured to manage live and on-demand topology information in the system
  • a server management module for managing information of each edge server.
  • the embodiment of the present invention further provides a core server CS, including: an information indexing module, configured to perform metadata extraction on the content source, and generate index information.
  • a content blocking module configured to block the content source, and determine an encoding format;
  • a content distribution module configured to distribute the index information generated by the information indexing module and the content of the content blocking module into blocks to a corresponding edge server.
  • the embodiment of the present invention further provides a live service edge server Live-ES, including:
  • a content management module for managing locally stored data
  • a content communication module configured to acquire locally required content, and process the received request
  • a content blocking management module configured to perform block coding on the acquired content
  • an embodiment of the present invention further provides an on-demand service edge server VOD ES, including:
  • a content management module for managing locally stored data
  • a content communication module configured to acquire content required locally, and process the received request
  • the SN management module is configured to manage the super node SN corresponding to the data according to the data managed by the content management module;
  • the cluster management module is configured to perform SN selection and deregistration on the accessed node.
  • an embodiment of the present invention further provides an SN, including:
  • a node status recording module configured to record status information of each node in the domain
  • the determining module is configured to determine, according to the status information of each node in the domain recorded by the node status recording module, whether the number of cache nodes of the content block of the data stream corresponding to the live broadcast service or the on-demand service is lower than the set content block level threshold.
  • the embodiment of the present invention further provides a P2P-based media playing system, including a core server CS and at least one Live-ES, VOD-ES, RRS, SN, and node:
  • the CS is used for performing uniform encoding on the content source, and sending the processed content source to the corresponding Live-ES or VOD-ES;
  • the L 1V e-ES is used to provide a data flow required for a live broadcast service
  • the VOD-ES is used to provide a data flow required for an on-demand service
  • the RRS is configured to manage the Live ES, the VOD ES, and the node in the network;
  • the SN is configured to manage each node and content in the domain;
  • the node is configured to receive, transmit, and store a data stream corresponding to a live or on-demand service.
  • the technical solution of the embodiment of the present invention has the following advantages, because the characteristics of the live broadcast and the on-demand video service are fully utilized, and the two are merged to realize the free switching from the live broadcast to the on-demand broadcast, and at the same time, the disk cache method is improved, and the program resources are evenly distributed.
  • the connectable node is added, and the data cached by the user node disk is used for on-demand.
  • the system determines whether to cache the currently viewed program according to the resource distribution, thereby avoiding the situation that sufficient content is used for the network application. Excessive repetitive storage of content causes waste, improves network resource utilization, and improves user experience.
  • FIG. 1 is a schematic structural diagram of a P2P-based media playback system according to an embodiment of the present invention
  • FIG. 2 is a schematic structural diagram of a core server CS according to an embodiment of the present invention.
  • FIG. 3 is a schematic structural diagram of a live service edge server Live-ES according to an embodiment of the present invention
  • FIG. 4 is a schematic structural diagram of an on-demand service edge server VOD-ES according to an embodiment of the present invention
  • FIG. VOD a schematic diagram of the data structure stored in the ES
  • FIG. 6 is a schematic structural diagram of a user request routing system RRS according to an embodiment of the present invention
  • FIG. 7 is a schematic structural diagram of a super node SN according to an embodiment of the present invention
  • FIG. 8 is a schematic structural diagram of a terminal node according to an embodiment of the present invention.
  • FIG. 9 is a schematic topological diagram of a P2P-based media playback system according to an embodiment of the present invention
  • FIG. 10 is a schematic diagram of a topology of a live broadcast node joining a point-on-demand in an embodiment of the present invention
  • FIG. 11 is a schematic diagram of a node from a live broadcast on-demand
  • FIG. 12 is a schematic diagram of a client process of a P2P-based media playing method according to an embodiment of the present invention
  • FIG. 13 is a schematic flowchart of a node login process according to an embodiment of the present invention
  • FIG. 14 is a schematic diagram of an operation flow of a live broadcast mode according to an embodiment of the present invention.
  • 16 is a schematic diagram of an operation flow of an on-demand mode in an embodiment of the present invention.
  • FIG. 17 is a schematic diagram of a process of determining whether to cache content in an embodiment of the present invention.
  • FIG. 18 is a schematic diagram of an operation flow of realizing a live mode to an on-demand mode switching by a live node dragging according to an embodiment of the present invention
  • FIG. 19 is a schematic flowchart of a node exiting a live broadcast according to an embodiment of the present invention.
  • the embodiment of the invention provides a peer-to-peer P2P-based media playing method.
  • the two are organically combined to realize the free switching from live to on-demand, and at the same time improve the disk caching method and make the program
  • the resources are evenly distributed and the connectable nodes are added, and the data cached by the user node disk is used for on-demand, and the nodes in the video service system are in the state of on-demand and live broadcast.
  • the system determines whether to cache the currently viewed program according to the distribution of resources, thereby avoiding excessive waste of stored content and saving waste when ensuring sufficient content for the network application, thereby improving network resource utilization and improving The user experience.
  • a schematic diagram of a P2P-based media playback system includes at least one core server CS 1 , a live service edge server Live ES 2 , and an on-demand service edge server VOD — ES 3 .
  • the user requests the routing system RRS 4, super node SN 5 and node 6.
  • the CS-processed program content having the same block coding mode is transmitted to the live service edge server Live-ES 2 and the on-demand service edge server VOD-ES 3 to provide a program source for the live broadcast and on-demand services.
  • Specific delivery methods include according to the edge server (including Live-ES 2 and VOD-ES 3) requests are transmitted, or CS 1 actively pushes, gp CS 1 transfers the chunked content to Live-ES 2 and VOD-ES 3
  • RRS 4 is responsible for program management of the entire system, and registers and manages the content on Live-ES 2 and VOD-ES 3 to provide a basis for resource optimization within the system.
  • the specific implementation method may be that CS 1 actively performs programs on RRS 4.
  • the content report can also be RRS 4 for content detection, and the program content sent by CS 1 to Live-ES 2 and VOD-ES 3 is detected. Further, the content detection can also discover changes in the Live-ES 2 and VOD-ES 3 content, thereby updating the corresponding content record on the RRS 4.
  • RRS 4 enables registration and management of topologies within the system.
  • SN 5 is the administrator of a domain of the on-demand service edge server VOD-ES 3, which is responsible for registering and managing the content partitioning in each node in the domain, and can further record the direct dialing service through the VOD-ES registration live network.
  • the content cached in the node is chunked.
  • the node 6 selects the optimal on-demand content providing node after accessing the system, and provides the on-demand service resource for the node 6.
  • the node 6 logs in to the network through the RRS 4, and knows which edge server the content of the node 6 needs to be located through the RRS 4, thereby performing corresponding live or on-demand services.
  • the schematic diagram of the core server CS 1 includes:
  • the information indexing module 21 is configured to perform metadata extraction on the content source to generate index information.
  • the index information is metadata information of a program, and includes information such as key frames of the program.
  • the content blocking module 22 blocks the content source with a certain encoding format.
  • the content distribution module 23 is configured to distribute the index information generated by the information indexing module 21 and the content partitioned by the content blocking module 22 to the corresponding edge server.
  • the information of the above-mentioned cable I is sent to the edge server together with the processed content, and the node first obtains the metadata information of the program from the edge server before performing the media playing service, and then obtains the specific data block according to the metadata.
  • CS 1 saves the correspondence between the chunked content and the edge server and passes CS 1
  • the processed content is pushed to the information record of the edge server, and its data structure can be in the manner of Table 1, as shown in Table 1:
  • Table 1 List of data structures in CS Specifically, Table 1 shows that the edge server ES-1, ES_2 ⁇ until ES-N have the content content corresponding to the Content ID on the edge server.
  • the edge server is used for live broadcast. Still on demand.
  • the corresponding relationship between the ES and the content embodied in the above data structure is used to ensure that CS 1 does not perform repeated or contradictory processing on the same content, thereby ensuring the efficiency of content processing, and at the same time, if CS 1 actively performs the RRS 4
  • the above data structure can also be used as a report content to provide content management basis for RRS 4.
  • the live service edge server L lve — ES 2 is used to provide the data stream required for the live broadcast service, and the Live ES 2 saves the block-processed program content obtained from the CS 1 , and the Live ES 2 becomes the block data in the system.
  • the provider provides the node with the relevant node information storing the content requested by the node.
  • the node cannot obtain the required data from the node connected thereto, it can also be from 1 ⁇ -ES. 2, the required data stream is obtained, wherein the structure of the Live-ES 2 can refer to FIG. 3, which specifically includes:
  • a content management module 31 configured to manage locally stored data, that is, used to manage content that is processed again by the block;
  • a content communication module 32 configured to acquire content required locally from the core server CS1, and process an acquisition request sent by another node;
  • the content blocking management module 33 is configured to perform block-by-block encoding on the content partition generated by the core server CS1.
  • the content needs to be encoded to form a block of N+R, that is, for the blocks distributed by the CS to the edge server ES, when it is necessary to distribute the blocks to other nodes,
  • Live-ES needs to perform block coding processing on these blocks again, forming N original small blocks and R coding blocks, and arbitrarily selecting N blocks in N+R coding blocks, and the client can It is reduced to the original content block.
  • On-demand service edge server VOD-ES 3 is used to provide the data flow required for on-demand services.
  • the VOD_ES 3 stores the block-processed program content acquired from the CS 1 and becomes the provider of the block data in the system, and provides the node with the relevant node information storing the content requested by the node.
  • the required data stream can also be obtained from the VOD-ES 3.
  • VOD_ES 3 can also be used as the super node SN 5 for content management and allocation.
  • the super node SN 5 for content management and allocation can also be set separately, but the super node SN 5 must be determined by VOD_ES 3. It accepts the management of VOD-ES 3.
  • RRS 4 assigns the contents of CS 1 to VOD-ES 3
  • SuperNode SN 5 is also selected and managed by VOD-ES 3.
  • the structure of the on-demand service edge server VOD-ES 3 can be referred to FIG. 4, and specifically includes: a content management module 41, configured to manage locally stored data, that is, content partitioning, the data may be attributed to different SNs, or may belong to the same One SN;
  • the content communication module 42 is configured to acquire content that is needed locally, and process an acquisition request sent by another node;
  • the SN management module 43 is used to manage SN nodes in different domains, and provides an interface for the user to query the SN.
  • the data structure is as shown in FIG. 5:
  • Content ID represents the ID of a program content
  • SN List indicates that the VOD-ES manages the SN list of the content
  • SN_ID represents the ID of a certain SN in the SN List
  • PeerAddr indicates the address of the SN corresponding to the SN_ID
  • PeerNum indicates how many registered nodes of the SN currently exist; SN—Resource indicates the current performance of the SN.
  • the cluster management module 44 is configured to perform SN selection on the accessed node. Specifically, the main function of the cluster management module 44 is to select and divide the SN for the entire VOD-ES login node, and select or deregister the SN from the nodes controlled by the VOD_ES 3.
  • RRS 4 used to manage Live-ES 2, VOD-ES 3 and Node 6 in the network.
  • RRS4 manages on-demand and live broadcast two systems: When each newly added live broadcast node registers with RRS 4, RRS 4 will Feedback to the location of the node in the live topology, and feedback the nearby nodes of the location to the node, and assign a Live-ES 2 to the node to ensure the QoS of the user experience; each newly added on-demand node will At the RRS 4, the VOD_ES 3 is obtained. At the same time, the RRS 4 manages all the nodes of the same program on demand, and sorts according to the playing time point. Therefore, the newly joined node also obtains a set of nodes near the playing point.
  • the RRS 4 needs to feed back the VOD_ES 3 of the program content, obtain the SN5 of the program content through the VOD-ES 3, and then register, in order to make The subsequent download of the stored content file block by node 6 can be used by the on-demand node.
  • the structure of the RRS 4 specifically includes:
  • the user management module 61 is configured to manage information about each node in the network, and assign a Peer ID to each logged-in node, including:
  • the determining sub-module 611 is configured to determine whether the number of data stream content cache nodes corresponding to the live broadcast service or the on-demand service is lower than a set file level threshold.
  • the topology management module 62 is configured to manage the live broadcast and on-demand topology information in the system, including:
  • the live topology management sub-module 621 is configured to manage the topology information corresponding to the live broadcast service.
  • the on-demand topology management sub-module 622 is configured to manage the topology information corresponding to the on-demand service.
  • the data structure managed by the topology management module on RRS 4 can use the cell shown in Table 2.
  • Table 2 List of data structures in RRS ContentID represents the ID of a certain program content;
  • MetaData represents the metadata of the content, including the content duration, the code rate, and the like.
  • Live-ES List represents a live ES list of the content of this program
  • the VOD ES List represents an on-demand ES list of the content of the program
  • the live topology records the live nodes that are watching the program, and the connections between the nodes;
  • the on-demand node list records the on-demand nodes that are watching the program, and sorts them according to the playback time point;
  • Live PeerNum and VOD PeerNum respectively indicate the number of nodes currently watching live and on-demand, and by these quantities, the RRS can feed back to a newly joined node about whether to store the received data.
  • the live topology management sub-module manages the location of each node in the live broadcast system in the live broadcast topology. When a new node joins the live broadcast system, it feeds back information about the corresponding neighbor node of the node;
  • the module is mainly used to record the information of each node in the on-demand system. When a new node is added to the on-demand system, the node will feed back the node near the playback time point to the new node.
  • the server management module 63 is configured to manage information of each edge server.
  • the server management module 63 manages the information of each edge server in the system, and can balance the load between the edge servers in the system. When a node joins, the server management module 63 can select some edge servers with better performance to pass to the node.
  • the structure of SN 5 is shown in Figure 7, including:
  • the node status recording module 71 is configured to record the status information of each node in the domain.
  • the determining module 72 is configured to determine the content of the data stream corresponding to the live broadcast service or the on-demand service according to the status information of each node in the domain recorded by the node status recording module 71. Whether the number of blocked cache nodes is lower than the set content block level threshold.
  • the SN exists in the on-demand system, and the node with good performance selected by the on-demand edge server VOD-ES from a plurality of common nodes saves a data structure and counts the distribution of nodes of each block in each management area, and In the statistical domain, the node information of the required data may be provided for other nodes, and the content of the content requested by the node is cached.
  • the schematic diagram of the data structure Reglnfo of the SN 5 may refer to Table 3, wherein the PeerList and Blocklnfo fields are specifically as follows. Table 4 and Table 5 show:
  • Blocklnfo Table 4 Schematic list of PeerList structure
  • Table 5 Schematic list of Blocklnfo structure
  • BlockID BlockNum where:
  • ContentID represents the ID of a program content
  • PeerList represents a node list of the program content managed by the SN and content block information owned by the nodes
  • Blocklnfo represents the block content information of the program content and the number of corresponding blocks
  • PeerlD represents an ID corresponding to each node
  • PeerAddr indicates the address information corresponding to each node
  • BlockBitmap represents the content block information owned by the node
  • PeerState indicates the state in which the node is located, which can be: on-demand, live broadcast, and idle (that is, neither on-demand nor live broadcast).
  • the state of the node changes, all SN nodes that locally cache content are notified, and they are required to change the corresponding PeerState;
  • BlocklD represents the ID of a block of program content
  • BlockNum represents the number of blocks corresponding to BlocklD in the SN management domain
  • Each content partition is registered once in SN 5.
  • the disk space of a certain user terminal is limited, and data replacement is involved.
  • the node sends a message to notify the SN 5 to keep updating, so that the statistical data and content distribution of the SN 5 are maintained. More realistic, the node gets a more reliable set of connectable nodes, and the hit rate is higher when connecting.
  • SN 5 records the current state of the node.
  • the state of the node changes for example, the node is switched from live broadcast to on-demand, and the idle state is transferred to the on-demand mode to watch the program. Involving the change of the node state, it is necessary to notify the registered SN. , inform the change of status, keep the data held by SN up to date.
  • the SN 5 When receiving the node request, the SN 5 selects at least one connectable node among all nodes in the domain to form a connectable node set, and sends the node set information to the corresponding request node according to the priority selection rule, and the priority selection rule includes It is not limited to selecting according to the priority order of the idle node, the on-demand node, and the live node.
  • the node 6 is configured to receive a data stream corresponding to the live broadcast or the on-demand service, and the structure thereof is as shown in FIG.
  • the login module 81 is used to log in to the network, and may include:
  • the cache judging sub-module 811 is configured to determine whether there is cache data on the node
  • the registration sub-module 812 is configured to: when the cache determination sub-module 811 determines that the cache data exists on the node, obtain the on-demand service information corresponding to the cached data from the RRS 4, and perform information registration of the cached data according to the on-demand service information.
  • the mode selection module 82 is configured to select a live broadcast service or an on-demand service, and report the report to the related edge server.
  • the information obtaining module 83 is configured to receive the live network topology information or the on-demand network topology information required for the live broadcast service or the on-demand service selected by the mode selection module 82, and whether the data flow corresponding to the live broadcast service or the on-demand service is cached. ;
  • the storage module 84 is configured to obtain a data stream according to the selection result of the mode selection module 82, and cache the data stream according to the determination result obtained by the information obtaining module 83, and specifically includes:
  • the download submodule 841 is configured to obtain a corresponding data stream according to the selection result of the mode selection module 82;
  • the buffer submodule 842 is configured to cache the data stream according to the judgment result obtained by the information obtaining module 841.
  • a topological diagram of a P2P-based media playback system is provided, wherein a left part is a node for watching a live program, and a right part is an on-demand mode and an idle state node.
  • the solid line connects to the live topology, and the dotted line connects the nodes related to the on-demand, forming an on-demand topology network.
  • Nodes E, F, and G have dual roles in the system: their own applications are live mode, which is in the network topology of live mode; the data cached by the disk is utilized by nodes in the on-demand mode, and thus plays in the on-demand topology.
  • live mode which is in the network topology of live mode
  • data cached by the disk is utilized by nodes in the on-demand mode, and thus plays in the on-demand topology.
  • the role of the flow has dual roles in the system: their own applications are live mode, which is in the network topology of live mode; the data cached by the disk is utilized by nodes in the on-demand mode, and thus plays in the on-demand topology. The role of the flow.
  • Nodes A, B, C, and D watch the program in live mode.
  • the system enters the system for the first time, its disk cache is empty, and no data blocks are available for on-demand use. Therefore, only live applications exist. Medium, but it has already registered with the on-demand SN of the program, and once the cached data block is downloaded, it reports and joins the on-demand topology.
  • Nodes I and J represent SNs in the on-demand topology.
  • Node 0 is an idle node that does not participate in program viewing, but its disk has cached data and enters the on-demand topology.
  • Nodes H, K, L, M, and N represent ordinary nodes in the on-demand mode.
  • Nodes H, I, J, K, L, M, N watch the program in the on-demand mode.
  • the live mode and the on-demand mode of the node can be switched:
  • the A node in the live mode caches the video data after a period of time, and joins the on-demand topology as the content provider.
  • Nodes H and L are streaming, and they are still watching the program in live mode, and the topology in the live broadcast remains unchanged, as shown in Figure 10.
  • node F the program viewing mode is switched from live broadcast to on-demand.
  • it needs to exit from the live broadcast topology, and only exists in the on-demand topology map, and becomes an on-demand node.
  • Exiting the live broadcast topology will inevitably lead to the change of the node relationship of the topology map.
  • the live broadcast topology needs to sense the impact of the F exit on other nodes, and quickly take measures: For example, the exit of the F from the live broadcast topology will result in the isolation of the G in the live broadcast topology. , unable to get live stream.
  • G is associated with other nodes in the live topology, for example, establishing a connection with node A to ensure normal data acquisition, as shown in FIG.
  • FIG. 12 it is a detailed flowchart of the technical solution proposed by the embodiment of the present invention.
  • the node enters the system and logs in to the network through RRS.
  • the node determines whether it has a cache of related content, and if so, obtains a VOD_ES corresponding to the cached content, and further obtains a corresponding SN through the VOD-ES, and registers the cached content information with the SN;
  • the node After the registration is completed, or when it is judged that there is no cache of related content, the node selects the section that it wishes to acquire.
  • the contents of the content, and the decision of the content is determined to be obtained through the direct live broadcast mode or the on-demand broadcast mode to perform the above-mentioned contents;
  • the LLiivvee-EESS, VVOODD-EESS, and neighbor neighbor node information of the corresponding phase are obtained from the RRRRSS. And whether it is to slow down the identification of the content of the cached content, and then, after obtaining the retrieved data stream by passing the above-mentioned information;
  • the VVOODD corresponding to the corresponding phase is obtained from the RRRRSS, and the set of information of the neighboring node points is as follows. And whether it is to slow down the identification of the content of the cached content, and then, after obtaining the retrieved data stream by passing the above-mentioned information;
  • the package further includes whether the data is cached according to whether the content of the content in the cache is determined according to whether the content is cached or not.
  • the judgement of the deposit is judged, and the specific package includes whether or not the judgment of the contents of the file at the level of the file is cached, and if the file is level-level cached, Then, the content of the file-level level corresponding to the storage storage phase is stored, and if it is not necessary to enter the file-level level cache, then it may be judged by one step.
  • the buffering of the inner content is divided into blocks, if not If the cache is not cached, then the 1100 discard cache will store the content partition block.
  • the node node clicks into the cache it can be entered.
  • the content is provided for internal content. .
  • the packet also includes a switchover between the direct broadcast mode mode and the point-on-demand mode.
  • the present invention will be divided into five parts and five parts, and the combination will be attached.
  • the diagram shows the description of the line, and the description of the specific body description is as follows:
  • the first part is divided into parts, as shown in FIG. 1133, in order to register the log flow process for the node node, among them, the node node enters the entry system system,
  • the first contact with RRRRSS is to log in to the network. .
  • the data is not reported to the RRRRSS. According to,, only log in. . Otherwise, the report data is reported to the RRRRSS, and the RRRRSS returns to the VVOODD-EESS information corresponding to the content of the buffer stored in the magnetic disk disk, and continues.
  • the SSNN registers the internal content content block information information cached by the node point of the node. .
  • the point pointed out is yes, there is a possibility that the node points can only go to this one, that is, only open the terminal End, but, but no longer continue to choose to choose direct live broadcast or or on-demand broadcast mode. .
  • This kind of situation is especially suitable for the application of the top box of the machine, so that the magnetic disk disk cache file file owned by the node point is It can be used by the point-to-point broadcast node in the top-of-the-line topology, in order to provide a stream for the point-to-point broadcast node. .
  • Figure 1133 shows the schematic diagram of the flow process when logging in with the user account, and the subsequent user is followed by the user.
  • the live broadcast, the dot-spot broadcast is still in the state of keeping the existing idle state of the idle state, and the specific package includes the following steps:
  • Step S1303 the RRS returns a series of VOD_ES related to the cached content. If the node disk does not have cached data, the RRS is only used for login, and does not return VOD—ES. After step S1304, the node obtains the VOD-ES information and then connects with the VOD-ES. Step S1305, VOD_ES returns the SN information of each content.
  • Step S1306 The node reports the content block information to the SN.
  • Step S1307 The SN modifies its internal data structure Reglnfo according to this, and records the newly added node and its content block information.
  • different content may be registered in the same SN, or in different SNs, and
  • the VOD ES can also be used as an SN.
  • the second part is the live mode operation process.
  • the node contacts the RRS to obtain the Live-ES information and the neighbor node information, and then establishes a relationship with the Live-ES and the neighbor node. Connection, completes the node joining the live topology.
  • the VOD-ES of the live content is obtained from the RRS, and a connection is established with the VOD-ES to obtain the SN information;
  • the RRS feedbacks whether the data is stored according to the heat of the program, and determines whether the newly added node caches the acquired data stream. For example, when a new node joins the program, if the node user currently using the content is more than the setting.
  • the node obtains the new download file of the program during the subsequent program viewing. Therefore, the node periodically checks whether there is content blocking (such as 4M is a Block). The download has been completed, and the report is registered with the SN. Information, determine whether to store the downloaded content in blocks. At this time, if the node in the live broadcast mode caches new content, it can join the on-demand topology of the content to supply the stream to the on-demand node.
  • content blocking such as 4M is a Block
  • a node in live broadcast may be in a dual structure: In the live topology, it benefits itself to serve other live nodes; in an on-demand topology, it provides cached data to nodes in the on-demand mode. If a node of the on-demand mode caches the content of a live broadcast program, the node of the on-demand mode can also be used as a node of the live broadcast mode. For the live broadcast and the on-demand broadcast, the topology and the supply flow are relatively stable, and the quality of the live broadcast can be guaranteed. Nodes in this on-demand mode may not be required to provide streaming support for viewing live nodes. Therefore, the idle node that is logged in can also be considered regardless of joining the live broadcast topology.
  • Step S1401 The node selects content to enter a live broadcast mode.
  • Step S1402 The node establishes a connection with the RRS and performs interaction.
  • Step S1403 Obtain edge server information (including Live-ES and VOD-ES corresponding to the content) and its neighbor nodes from the RRS.
  • the RRS determines whether the new joining node caches the live content (ie, file level cache).
  • Step S1404 Establish a connection with the Live-ES to interact.
  • Step S1405 Obtain a fast video data buffer from the Live-ES, and the step is an optional step.
  • Step S1406 Establish a connection with the VOD-ES of the content, and perform interaction.
  • Step S1407 Obtain the content SN information.
  • Step S1408 Interact with the Peers indicated in the SN information to obtain the required content data.
  • the node joins the appropriate location in the live topology, establishes a connection with the neighboring node to watch the program, and downloads data from the neighboring node or Live-ES.
  • Step S1409 Detect whether a part of the complete content block has been downloaded, and if yes, register the content block, and proceed to step S1410; otherwise, return to step S1408 to continue acquiring data.
  • Step S1410 Register file block information with the SN. The SN determines whether the block is cached according to the file cache result and the storage condition of the content block in the managed domain (here, the cache for the content block, if the file level cache judgment result is true, then there is no need to judge here, directly Store and register with SN).
  • Step S1411 The SN modifies its data structure Reglnfo to keep the data updated.
  • Step S1412 returning the registration result.
  • VOD_ES represents an on-demand edge server of the live program
  • Live-ES represents the live edge server of the live show
  • Flag indicates whether the program is buffered. 1 indicates storage and 0 indicates no storage.
  • NeighborList indicates the neighbor node of the program in the live topology; where there is a data structure in the List, PeerlD indicates the unique identifier of the node in the system, PeerAddr indicates the IP address of the node; and Relation indicates the relationship between the node and the requesting node. The relationship, including the node is the grandparent node of the requesting node, the father node, the child node, and the grandchild node. The requesting node only connects the parent node and the child node. Get data from the parent node and pass the data to the child node. When one of the nodes is dropped, there are other nodes that notify and get the replaced node of that class.
  • the third part is the operation flow of the on-demand mode.
  • the node sends a request for obtaining content to the VOD ES, and obtains an SN letter related to the requested content. Interest.
  • the VOD-ES obtains the fast cache data (this step is an optional step), and selectively establishes a connection with the acquired node to obtain content data.
  • a node query request is initiated to the SN, and the node is obtained, and the SN is locally registered according to each node (on-demand mode, live mode, or idle state).
  • the node with idle status is preferentially selected, then the node in the on-demand mode, the most is the live mode node, and the feedback is given to the node.
  • the reason for the selection The idle node has enough free resources, and the live node is stable in the topology. Get/deliver data, consume bandwidth.
  • FIG. 16 the schematic diagram of the on-demand mode process is as shown in FIG. 16, and includes the following steps:
  • Step S1601 The user selects an on-demand program to enter the on-demand mode.
  • Step S1602 First, the node contacts the RRS.
  • Step S1603 Obtain VOD-ES information from the RRS, and obtain metadata information, a number of nodes currently using the content (or whether to identify whether the program content file level cache is performed), and information of a node adjacent to the play point.
  • Step S1604 Establish a connection with the VOD-ES to interact.
  • Step S1605 Acquire information about the program content fast data buffer (optional) and SN.
  • Step S1606 Establish a connection with the SN.
  • Step S1607 Obtain a list of connectable nodes from the SN for establishing a connection.
  • Step S1608 interacting with the Peers indicated in the SN information to obtain the required data.
  • the node selects the node or VOD_ES selected from the list of learned nodes, and establishes connection download data.
  • the SN can return the node with a relatively large downlink bandwidth according to the flag information attached to the node.
  • Step S1609 Detect whether a part of the complete content block has been downloaded, and if yes, register the content block, and proceed to step S1610; otherwise, return to step S1608 to continue acquiring data.
  • Step S1610 Once the content is divided into blocks, the content registration is performed to the SN, and the SN determines whether the block is cached according to the storage condition of the content block in the managed domain (if the file level cache judgment result is true, then It can be stored directly and registered with the SN without judgment.
  • Step S1611 the SN modifies its internal data structure and keeps updating.
  • Step S15612 returning the registration result.
  • VOD ES Playpoint Nodes Flag where VOD_ES: indicates the on-demand edge server of the program
  • Playpoint Nodes indicates the node near the point in time at which the node is about to play
  • Flag A flag indicating whether or not to cache the program. 0 means no save, 1 means slow down.
  • the fourth part, as shown in Figure 17, is the judgment flow of whether or not to cache the content.
  • Step S1701 Set the number of cache nodes required for the service to be a file level threshold, and set the number of cached content blocks required by the service to be a content block level threshold.
  • Step S1702 Compare whether an existing cache node recorded in the RRS is higher than a file level threshold. When the number of existing nodes for buffering the data stream corresponding to the live broadcast service or the on-demand service recorded in the RRS is lower than the file level threshold, the process proceeds to step S1703;
  • Step S1703 Determine file level cache for the data stream corresponding to the live broadcast service or the on-demand service.
  • the node When judging file-level caching, it is sure to cache the current content partition. At this point, the node downloads a file block, puts it in memory, does not immediately write to the disk, registers with the SN, and waits until the SN returns the result, then writes the content from the memory to the disk. By default, the write is successful, no longer. Interaction ⁇ ' If the write is not successful, the node sends a message to the SN, and the SN modifies the statistics of the corresponding content block.
  • Step S1704 If the file level buffer is not performed, compare whether the number of content blocks buffered in the SN is higher than a content block level threshold.
  • the node registers the on-demand SN of the content (in units of blocks), and the SN returns a registration result, and displays the content block information owned by the node managed by the SN, and the node determines whether to cache the downloaded block according to the result returned by the SN, specifically For:
  • step S1705 When the content block number of the cached content recorded in the SN is lower than the content block level threshold, the process proceeds to step S1705;
  • step S 1706 When the content block number of the cached content recorded in the SN is higher than the content block level threshold, the process proceeds to step S 1706.
  • Step S1705 Determine to perform content block caching on the current content partition.
  • Step S1706 Determine that the data stream and the current content are not cached.
  • the file level comparison (the program viewing node in the topology) exceeds the threshold and the micro content partition comparison (the storage amount of the file block in the SN managed domain) exceeds the threshold, when both conditions are met, File and content are not stored in chunks.
  • the fifth part is to perform live mode to on-demand by dragging through the live node.
  • the node may switch programs or switch modes at any time during the program broadcast:
  • the live node drags into the on-demand mode, the on-demand node drags or switches the program.
  • the node For switching from the live mode to the on-demand mode, the node exits from the live topology, maintains its position in the on-demand topology, and then obtains the SN information and the fast data buffer from the Vod-ES of the on-demand content, and obtains the drag point from the SN node.
  • the set of connected nodes is the same as the operation of entering the on-demand.
  • the node is switched from the live mode to the on-demand mode, and the acquisition mode of the video stream generally changes.
  • the node needs to exit from the live topology map and join the on-demand topology map; or keep the location in the live broadcast topology to avoid frequent changes in the live broadcast topology and reduce the disturbance.
  • the on-demand node forwards the video stream as an intermediate node in the live broadcast topology.
  • the advantage is that the live broadcast topology is stabilized and the operation is avoided.
  • the disadvantage is that the live topology may become abnormally large. Many intermediate nodes do not directly need the live mode to provide the playback stream. Therefore, we choose to exit the node from the live topology. 11 is shown.
  • the probability of sibling with the live broadcast after a certain time is extremely small, and it is possible to ignore the situation in which a program on-demand node subsequently enters the live broadcast mode of the program.
  • the node enters the on-demand mode signaling interaction by dragging the live broadcast point.
  • the node enters the on-demand mode from the live broadcast mode.
  • the node needs to exit from the live broadcast topology and obtain the node information of the playback time point after the drag, including The following steps:
  • Step S1801 The user drags the live spot in the live mode.
  • Step S1802 Registering with the RRS to exit the live broadcast mode, the node will be cut into the on-demand mode and the cut-in playpoint. At this time, the node notifies the RRS to exit the live broadcast list and enter the on-demand list, and the RRS changes the saved data according to the current actual situation of the node.
  • Table 7 List of data structures sent by nodes to RRS during live-to-on-demand mode switching
  • ContentID represents a program content ID
  • PeerlD represents the node ID
  • SwitchFlag indicates that the node switches from the live broadcast mode to the on-demand mode flag.
  • SwitchPoint indicates the playback time point after the node cuts into the on-demand.
  • Step S1803 Returning the node information of the playback time point after the drag from the RRS, and selecting a node when establishing the connection.
  • Step S1804 Check whether the local has enough data. If not, the node requests fast data buffering from the VOD-ES.
  • Step S1805 VOD-ES returns data to the node to reduce the drag delay.
  • Step S1806 The node requests the SN to register the node with the requested data.
  • Step S1807 Obtain a node list from the SN.
  • Step S1808 Interact with Peers to obtain the required data.
  • Step S1809 Detect whether a part of the complete content block has been downloaded, and if yes, register the content block, and proceed to step S1810; otherwise, return to step S1808 to continue acquiring data.
  • Step S1810 After some content block downloading is completed, the SN registration information SN determines whether the block is cached according to the storage condition of the content block in the managed domain. (If the file level cache Num - File ⁇ Nl is judged to be true, then it is not necessary to judge, directly store, register with the SN).
  • Step S1811 SN modifies its data structure RegInfo.
  • Step S1812 returning the registration result.
  • the node that is about to exit can have two options: Proactively initiate an exit request, such as initiating an exit notification to the live ES or its neighbor nodes, so that the self-organizing network can actively respond to the topology.
  • Proactively initiate an exit request such as initiating an exit notification to the live ES or its neighbor nodes, so that the self-organizing network can actively respond to the topology.
  • the other method is passive, not actively notifying its nodes in the live topology, but leaving directly, detecting its departure by its neighbors, taking the strategy, and adapting.
  • Step S1901 The user selects the switching mode and enters the on-demand.
  • Step S1902 When the node exits, the notification is actively sent to notify the Live-ES.
  • Step S1903 Live-ES sends a notification to other nodes.
  • Step S1904 The network self-organizing dynamically adjusts to respond to node changes in the network.
  • the technical solution of the present invention further includes other switching processes, specifically:
  • the process of switching the program by the live node is similar to the process of selecting the program for the first time, except that it maintains its position in the on-demand topology, notifies the corresponding SN to modify the node status information, and exits its live topology in the previous program.
  • the on-demand node can switch to live mode, switch programs to on-demand or live broadcast.
  • the SN modifies the state information of the node, enters the live broadcast topology of the new program; switches the program into on-demand or live broadcast, with the first time
  • the interaction to enter the on-demand and live broadcast is the same, it is also maintained at the location of the original on-demand topology map, and informs the state of the SN modified node with the cached data registration.
  • the technical solution of the embodiment of the present invention has the following advantages, because the characteristics of the live broadcast and the on-demand video service are fully utilized, and the two are merged to realize the free switching from the live broadcast to the on-demand broadcast, and at the same time, the disk cache method is improved, and the program resources are evenly distributed.
  • the connectable node is added, and the data cached by the user node disk is used for on-demand.
  • the system determines whether to cache the currently viewed program according to the resource distribution, thereby ensuring that there is enough content for the network application. It avoids excessive duplication of storage content and wastes, improves network resource utilization, and improves user experience.
  • the invention can be implemented by hardware, or can be realized by means of software plus necessary general hardware platform.
  • the technical solution of the present invention can be embodied in the form of a software product, which can be stored in a non-volatile state.
  • the storage medium (which may be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform the embodiments of the present invention. method.

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Multimedia (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • General Engineering & Computer Science (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
  • Information Transfer Between Computers (AREA)

Description

一种基于 P2P的媒体播放方法、 装置和系统 技术领域
本发明涉及多媒体传输领域, 特别是涉及一种基于 P2P的媒体播放的 方法、 装置和系统。
背景技术
随着因特网技术的普及, 90年代后期, 以 Napster为代表的 p2p应用开 始在因特网上流行。 P2P即对等计算或对等网络, 节点通过直接交换来共享 资源和服务, 每个节点既可以是服务器, 也可以是客户端。
一般说来, 基于 P2P的视频服务包括直播和点播两种。
视频直播是指由服务器定时播放节目, 用户在终端收看节目, 如同电视 的播放模式一般。 其拓扑构架具有如下特点: 以服务器为中心构建拓扑, 每 一个直播边缘服务器负责管理一部分节目, 与 Peer (节点) 进行交互, 提 供节目数据缓冲, 并负责将新加入节点插入拓扑的某个位置。
视频点播是指能在用户需要时随时提供交互式视频服务的业务。 其拓扑 架构具有如下特点: 以服务器为中心构建的点播拓扑架构, 具体实现可以为 网状、 树形等方式, 以 SN ( Super Node, 超级节点) 为构成主干网络, 每 个 SN负责管理某一个区域, 与 Peer进行交互, 提供可连接的节点列表。
发明人在实现本发明的过程中发现现有技术中至少存在如下缺点: 基于 P2P的视频服务系统中的直播和点播的功能的实现是相对独立的, 没有做到 这两种播放方式的融合, 且各自存在着一些问题: 直播节目顺畅清晰, 但不 能拖动; 点播节目满足用户能随时播放的意愿, 但是需要用户查询相关的节 目, 拖动延迟大, 缓冲时间长, 节目流畅度有待提高。 且各个终端节点都有 一个磁盘缓存用户已经收看的数据, 但这些被缓存的数据没有被充分利用。 发明内容
有鉴于此, 有必要提出一种基于 P2P的媒体播放方法, 可以实现直播 和点播业务的融合和两种播放模式的自由切换。
一种基于点对点 P2P的媒体播放方法, 包括以下歩骤:
登录网络;
选择直播业务或点播业务, 并接收是否对所述直播业务或点播业务对应 的数据流进行缓存的判断结果;
根据所述选择结果获取所述对应的数据流, 并在所述判断结果为是时, 对所述数据流进行缓存;
所述缓存的对应数据流分别作为点播业务或直播业务的数据源提供给点 播节点或直播节点。
另一方面, 本发明实施例还提供了一种节点, 包括:
登录模块, 用于登录网络;
模式选择模块, 用于选择直播业务或点播业务;
信息获取模块, 用于接收所述模式选择模块所选择的直播业务或点播业 务所需的网络信息和是否对所述直播业务或点播业务对应的数据流进行缓存 的判断结果;
存储模块, 用于根据所述模式选择模块的选择结果获取所述数据流, 并 根据所述信息获取模块所获取的判断结果为进行缓存时对所述数据流进行缓 存。
另一方面, 本发明实施例还提供了一种用户请求路由系统 RRS , 包 括:
用户管理模块, 用于管理节点信息;
拓扑管理模块, 用于管理系统内直播和点播拓扑结构信息;
服务器管理模块, 用于管理各边缘服务器的信息。
另一方面, 本发明实施例还提供了一种核心服务器 CS, 包括: 信息索引模块, 用于对所述内容源进行元数据提取, 生成索引信息。 内容分块模块, 用于对所述内容源进行分块, 确定编码格式; 内容分发模块, 用于将所述信息索引模块生成的索引信息和所述内容分 块模块分块的内容分发到相应的边缘服务器。
另一方面, 本发明实施例还提供了一种直播业务边缘服务器 Live— ES, 包括:
内容管理模块, 用于管理本地存放的数据;
内容通信模块, 用于获取本地需要的内容, 并处理接收的请求; 内容分块管理模块, 用于所述获取的内容的进行分块编码。
另一方面, 本发明实施例还提供了一种点播业务边缘服务器 VOD ES, 包括:
内容管理模块, 用于管理本地存放的数据;
内容通信模块, 用于获取本地需要的内容, 并处理接收的请求;
SN管理模块, 用于根据所述内容管理模块所管理的数据, 管理所述数 据相对应的超级节点 SN;
簇管理模块, 用于对接入的节点进行 SN选择与注销。
另一方面, 本发明实施例还提供了一种 SN, 包括:
节点状态记录模块, 用于记录域内的各节点的状态信息;
判断模块, 用于根据所述节点状态记录模块所记录的域内各节点状态信 息判断直播业务或者点播业务对应的数据流的内容分块的缓存节点数量是否 低于设置的内容分块级阈值。
另一方面, 本发明实施例还提供了一种基于 P2P的媒体播放系统, 包 括核心服务器 CS和至少一个 Live— ES、 VOD— ES、 RRS、 SN和节点:
所述 CS, 用于对内容源进行统一编码的处理, 并将所述处理后的内容 源发送给对应的 Live— ES或 VOD— ES;
所述 L1Ve— ES, 用于提供直播业务所需的数据流;
所述 VOD— ES, 用于提供点播业务所需的数据流;
所述 RRS, 用于管理网络中的所述 Live ES、 VOD ES和节点; 所述 SN, 用于管理域内各节点和内容;
所述节点, 用于接收、 传输和存储直播或点播业务所对应的数据流。 本发明实施例的技术方案具有以下优点, 因为充分利用了直播和点播视 频服务的特点, 将二者进行融合, 实现了直播到点播的自由切换, 同时改进 磁盘缓存方法, 使节目资源均衡分布并增加可连接节点, 并将用户节点磁盘 缓存的数据用于点播, 此外, 系统根据资源分布情况, 判断是否对当前收看 节目进行缓存, 从而, 在保证有足够内容用于网络应用的情况下, 避免了过 多重复存储内容而造成浪费, 提高了网络资源利用率, 改善了用户使用体 验。
附图说明
图 1 为本发明实施例中一种基于点对点 P2P的媒体播放系统的结构示 意图;
图 2为本发明实施例中核心服务器 CS的结构示意图;
图 3为本发明实施例中直播业务边缘服务器 Live— ES的结构示意图; 图 4为本发明实施例中点播业务边缘服务器 VOD— ES的结构示意图; 图 5为本发明实施例中点播业务边缘服务器 VOD— ES中存储的数据结 构示意图;
图 6为本发明实施例中用户请求路由系统 RRS的结构示意图; 图 7为本发明实施例中超级节点 SN的结构示意图;
图 8为本发明实施例中终端节点的结构示意图;
图 9为本发明实施例中一种基于 P2P的媒体播放系统的拓扑示意图; 图 10为本发明实施例中直播节点后续加入点播的拓扑示意图; 图 11为本发明实施例中节点从直播切入点播模式的拓扑示意图; 图 12为本发明实施例中一种基于 P2P的媒体播放方法的客户端流程示 意图;
图 13为本发明实施例中节点登录流程示意图; 图 14为本发明实施例中直播模式的操作流程的示意图;
图 15本发明实施例中直播模式下 RRS反馈的数据结构列表;
图 16为本发明实施例中点播模式的操作流程的示意图;
图 17为本发明实施例中是否缓存内容的判断流程示意图 ·'
图 18为本发明实施例中通过直播节点拖动, 实现直播模式到点播模式 切换的操作流程示意图;
图 19为本发明实施例中节点退出直播的流程示意图。
具体实施方式
本发明实施例提出一种基于点对点 P2P的媒体播放方法, 在实现直播 和点播功能的基础上, 将二者有机地结合起来, 实现了直播到点播的自由切 换, 同时改进磁盘缓存方法, 使节目资源均衡分布并增加可连接节点, 并将 用户节点磁盘缓存的数据用于点播, 视频服务系统中的节点处于点播和直播 共生的状态中。 此外, 系统根据资源分布情况, 判断是否对当前收看节目进 行缓存, 从而, 在保证有足够内容用于网络应用的情况下, 避免过多重复存 储内容而造成浪费, 提高了网络资源利用率, 改善了用户使用体验。
如图 1所示, 本发明实施例提出的一种基于点对点 P2P的媒体播放系 统结构示意图, 包括至少一个核心服务器 CS 1、 直播业务边缘服务器 Live— ES 2、 点播业务边缘服务器 VOD— ES 3、 用户请求路由系统 RRS 4、 超 级节点 SN 5和节点 6。
其中 CS 1, 即为核心服务器 Core Server, 每一个节目内容作为数据 源, 加入到系统, 都需要首先由 CS进行处理, 保证节目内容不管是处于直 播还是点播中, 都具有同样的编码模式。 也就是说, 具有同一个 Content ID 的节目内容具有相同的分块编码方式, 该内容在直播系统和点播系统中对应 的分块是一致的。 经 CS处理后的具有相同分块编码方式的节目内容被传送 至直播业务边缘服务器 Live— ES 2和点播业务边缘服务器 VOD— ES 3中, 为 直播和点播业务提供节目源。 具体的传送方式包括根据边缘服务器 (包括 Live— ES 2禾 Π VOD— ES 3 ) 的请求进行传送, 或者是 CS 1主动推送, gp CS 1 将分块后的内容传送给 Live— ES 2和 VOD— ES 3
RRS 4负责整个系统的节目管理, 对 Live— ES 2和 VOD— ES 3上的内容 进行登记和管理, 为系统内的资源优化提供依据, 具体的实现方式可以是 CS 1主动向 RRS 4进行节目内容的汇报, 也可以是 RRS 4进行内容检测, 检测到 CS 1发送给 Live— ES 2和 VOD— ES 3的节目内容。 进一歩的, 内容 检测还可以发现 Live— ES 2和 VOD— ES 3内容的变化, 从而更新 RRS 4上的 相应内容记录。 此外, RRS 4还可以实现对系统内的拓扑结构的登记和管 理。
SN 5作为点播业务边缘服务器 VOD— ES 3的一个域的管理者, 其负责 登记和管理域内各节点中的内容分块, 并且, 可以进一歩的通过 VOD— ES 登记直播网络中进行直拨业务的节点中所缓存的内容分块。 通过上述内容分 块的等级和管理, 为节点 6接入系统后选择最优的点播内容提供节点, 为节 点 6提供点播业务资源。
节点 6通过 RRS 4登录网络, 并通过 RRS 4获知节点 6需要的内容位 于哪个边缘服务器, 从而进行相应的直播或点播业务。
如图 2所示, 为核心服务器 CS 1的结构示意图, 具体包括:
信息索引模块 21, 用于对内容源进行元数据提取, 生成索引信息。 索 引信息是一个节目的元数据信息, 包含节目的关键帧等信息。
内容分块模块 22, 采用一定的编码格式对内容源进行分块。
内容分发模块 23, 用于将信息索引模块 21生成的索引信息和内容分块 模块 22分块后的内容分发到相应的边缘服务器。
上述索弓 I信息随处理后的内容一并发送给边缘服务器, 节点进行媒体播 放业务前首先从边缘服务器上获取节目的元数据信息, 之后, 根据元数据获 取具体的数据块。
此外, CS 1保存了分块后的内容与边缘服务器的对应关系和经过 CS 1 处理的内容推送到边缘服务器的信息记录, 其数据结构可以采用表 1 的方 式, 请参见表 1所示:
表 1 CS中数据结构列表
Figure imgf000009_0001
具体的, 表 1表示在边缘服务器 ES— 1、 ES_2 ······直到 ES— N这些边缘 服务器上都有对应 Content ID的节目内容, 当然, 也可以进一歩指出边缘服 务器是用于直播还是点播。
上述的数据结构所体现的 ES和内容的对应关系用于保证 CS 1不会对 相同的内容做出重复的或矛盾的处理, 保证了内容处理的效率, 同时, 如果 CS 1主动向 RRS 4进行节目内容的汇报, 上述的数据结构同样可以作为汇 报内容, 为 RRS 4提供内容管理依据。
直播业务边缘服务器 Llve— ES 2用于提供直播业务所需的数据流, Live— ES 2保存了从 CS 1获取的分块处理后的节目内容, Live— ES 2成为系 统中分块数据的提供者, 为节点提供存储有该节点所请求内容的相关节点信 息, 当然为了保证用户的服务质量 QoS, 如果节点不能从与其连接的节点 中获取所需要的数据, 也可以从1^^— ES 2中获取需要的数据流, 其中, Live— ES 2的结构可以参考图 3, 具体包括:
内容管理模块 31, 用于管理本地存放的数据, 即用于管理再次分块处 理后的内容;
内容通信模块 32, 用于向核心服务器 CS 1获取本地需要的内容, 并处 理其他节点发送的获取请求;
内容分块管理模块 33, 用于对核心服务器 CS 1所生成的内容分块进行 再次分块编码。
在内容分发过程中, 需要对内容进行编码处理, 形成 N+R的块, 即对 于由 CS分发到边缘服务器 ES中的块, 当需要把这些块分发给其他节点即 其他客户端的时候, Live— ES需要再次对这些分块进行分块编码处理, 形成 N原始的小块和 R个编码块, 在 N+R个编码块中任意选择 N块, 客户端都 可以将其还原成原始的内容分块。
点播业务边缘服务器 VOD— ES 3用于提供点播业务所需的数据流。
VOD_ES 3保存了从 CS 1获取的分块处理后的节目内容, 成为系统中 分块数据的提供者, 为节点提供存储有该节点所请求内容的相关节点信息。 当然, 为了保证用户的服务质量 QoS, 如果节点不能从与其连接的节点中 获取所需要的数据, 也可以从 VOD— ES 3 中获取需要的数据流。 其中, VOD_ES 3还可以进一歩兼作超级节点 SN 5进行内容的管理和分配, 当然 进行内容的管理和分配的超级节点 SN 5也可以单独设置, 但超级节点 SN 5 必须由 VOD— ES 3进行确定的, 其接受 VOD— ES 3的管理。 在 RRS 4将 CS 1中的内容指派给 VOD— ES 3时, 超级节点 SN 5也是由 VOD— ES 3进行选 取和管理的。
点播业务边缘服务器 VOD— ES 3的结构可以参考图 4, 具体包括: 内容管理模块 41, 用于管理本地存放的数据, 即内容分块, 该数据可 以归属于不同的 SN, 也可以归属于同一个 SN;
内容通信模块 42, 用于获取本地需要的内容, 并处理其他节点发送的 获取请求;
SN管理模块 43, 用于管理不同域的 SN节点, 为用户查询 SN提供接 口, 其数据结构如图 5所示:
其中:
Content ID表示某节目内容的 ID;
SN List表示 VOD— ES管理该内容的 SN列表;
SN— ID表示 SN List中的某个 SN的 ID;
PeerAddr表示与 SN— ID对应的 SN的地址;
PeerNum表示该 SN目前拥有多少个登记内容的节点; SN— Resource表示目前该 SN的性能使用状况。
簇管理模块 44, 用于对接入的节点进行 SN选择。 具体为: 簇管理模块 44的主要作用是针对整个 VOD— ES登录的节点进行 SN的选择和划分, 从 VOD_ES 3所控制的节点中选择或注销 SN。
RRS 4, 用于管理网络中的 Live— ES 2、 VOD— ES 3和节点 6。
无论用户是选择点播还是直播, 用户所对应的节点都需要到 RRS 4上 进行登记, RRS4上管理点播和直播两套系统: 每一个新加入的直播节点到 RRS 4进行登记的时候, RRS 4会反馈给该节点在直播拓扑中的位置, 并把 该位置的附近节点反馈给该节点, 同时分配给该节点一个 Live— ES 2, 保证 用户体验的 QoS; 每一个新加入的点播节点, 会从 RRS 4处获得 VOD— ES 3, 同时, RRS 4管理着点播同一节目的所有节点, 并根据播放时间点进行 排序, 因此, 新加入节点还会获得一个该播放点附近的节点集合。
节点 6在登录 RRS 4的时候, 无论是加入直播还是点播系统, 都需要 RRS4反馈回该节目内容的 VOD— ES 3, 通过该 VOD— ES 3获取节目内容的 SN5 , 然后进行登记, 目的是使节点 6后续下载存储的内容文件块可以为点 播节点使用。
如图 6所示, RRS 4的结构具体包括:
用户管理模块 61, 用于管理网络中各节点的信息, 并为每一个登录的 节点分配一个 Peer ID, 具体包括:
判断子模块 611, 用于判断直播业务或者点播业务对应的数据流内容缓 存节点数量是否低于设置的文件级阈值。
拓扑管理模块 62, 用于用于管理系统内直播和点播拓扑结构信息, 具 体包括:
直播拓扑管理子模块 621, 用于管理直播业务对应的拓扑结构信息; 点播拓扑管理子模块 622, 用于管理点播业务对应的拓扑结构信息。 其中 RRS 4上的拓扑管理模块管理的数据结构可以采用表 2所示的格 表 2 RRS中数据结构列表
Figure imgf000012_0001
ContentID表示某一个节目内容的 ID;
MetaData表示该内容的元数据, 包括, 内容时长、 码率等表示内容的 自 .
Live— ES List表示此节目内容的直播 ES列表;
VOD ES List表示此节目内容的点播 ES列表;
直播拓扑结构记录了正在收看此节目的直播节点, 以及节点之间的连接 关系;
点播节点列表记录了正在收看此节目的点播节点, 并按播放时间点进行 排序;
Live PeerNum和 VOD PeerNum分别表示目前正在观看直播和点播的节 点数量, 通过这些数量, RRS可以反馈给新加入的一个节点关于是否存储 接收到数据的消息。
直播拓扑管理子模块管理加入直播系统中每一个节点所处在直播拓扑图 中的位置, 当一个新节点加入直播系统的时候, 会反馈给该节点其相应的邻 居节点的信息; 点播拓扑管理子模块主要是用于记录每一加入点播系统中的 节点的信息, 当一个新节点加入到点播系统中, 节点就会把播放时间点附近 的节点反馈给这个新节点。
服务器管理模块 63, 用于管理各边缘服务器的信息。
具体为, 服务器管理模块 63 管理系统中各边缘服务器的信息, 可以均 衡系统中各边缘服务器之间的负载。 当有节点加入的时候, 通过服务器管理 模块 63可以选择一些性能比较好的边缘服务器传递给该节点。
SN 5的结构如图 7所示, 包括: 节点状态记录模块 71, 用于记录一个域内的各节点的状态信息; 判断模块 72, 用于根据节点状态记录模块 71所记录的域内各节点状态 信息判断直播业务或者点播业务对应的数据流的内容分块的缓存节点数量是 否低于设置的内容分块级阈值。
SN存在于点播系统中, 由点播边缘服务器 VOD— ES从众多普通节点中 选择的性能良好节点, 保存一个数据结构, 统计出其管理区域内, 每一个内 容的每一个块的节点分布情况, 并统计域内可以为其他节点提供所需要的数 据的节点信息, 并对节点所请求的内容分块是否缓存进行判断, SN 5 的数 据结构 Reglnfo的示意图可以参考表 3, 其中的 PeerList和 Blocklnfo字段具 体如表 4和表 5所示:
表 3 数据结构 Reglnfo的结构示意列表
ContentID
PeerList
Blocklnfo 表 4 PeerList的结构示意列表
Figure imgf000013_0001
表 5 Blocklnfo的结构示意列表
BlockID BlockNum 其中:
ContentID表示某节目内容的 ID;
PeerList表示该 SN管理的该节目内容的节点列表以及这些节点拥有的 内容分块信息;
Blocklnfo表示该节目内容分块信息以及对应分块的数量; PeerlD表示每个节点对应的一个 ID;
PeerAddr表示每个节点对应的地址信息;
BlockBitmap表示该节点拥有的内容分块信息;
PeerState表示节点所处在的状态, 可以是: 点播、 直播和闲置 (即既没 有点播也没有直播) , 当节点状态改变的时候, 就会通知所有本地缓存内容 的 SN节点, 要求它们改变对应的 PeerState;
BlocklD表示节目内容的某块的 ID;
BlockNum表示与 BlocklD对应的块在该 SN管理域内的数量;
每一个内容分块在 SN 5 进行一次登记, 在修改 PeerlD 对应的 BlockBitmap 对应的 bit位的同时, 还需要修改登记块 BlocklD 对应的 BlockNum, 如果需要登记, 则标记为 BlockNum++; 否则, 如果节点写磁 盘操作失败, 则回滚, 修改 bit位, 并标记为 BlockNum- -。
此外, 某个用户终端的磁盘空间有限, 涉及数据替换, 当新下载的内容 分块将原来的数据块替换时, 节点发送信息通知 SN 5保持更新, 使得 SN 5 拥有的统计数据和内容分布情况较真实, 节点得到的可连接节点集更可靠, 进行连接时的命中率比较高。
SN 5记录了节点当前所处的状态, 当节点状态发生改变时, 比如节点 由直播切入点播, 由闲置状态转入点播模式收看节目等, 涉及节点状态的改 变, 就需要通知其登记到的 SN, 告知其状态的改变, 保持 SN所持有的数 据最新。
SN 5收到节点请求时, 按照优先级选择规则, 在域内所有节点中选择 至少一个可连接节点组成可连接的节点集, 并发送节点集的信息给相应的请 求节点, 优先级选择规则包括但不仅限于按照闲置节点、 点播节点、 直播节 点的优先级顺序进行选择。
节点 6, 用于接收直播或点播业务所对应的数据流, 其结构如图 8所 示, 具体包括: 登录模块 81, 用于登录网络, 可以进一歩包括:
缓存判断子模块 811, 用于判断节点上是否存在缓存数据;
登记子模块 812, 用于当缓存判断子模块 811判断出节点上存在缓存数 据时, 从 RRS 4获取缓存数据对应的点播业务信息, 并根据点播业务信息 进行缓存数据的信息登记。
模式选择模块 82, 用于选择直播业务或点播业务, 上报给相关的边缘 服务器;
信息获取模块 83, 用于接收模式选择模块 82所选择的直播业务或点播 业务所需的直播网络拓扑信息或点播网络拓扑信息, 以及是否对直播业务或 点播业务对应的数据流进行缓存的判断结果;
存储模块 84, 用于根据模式选择模块 82的选择结果获取数据流, 并根 据信息获取模块 83所获取的判断结果对数据流进行缓存, 具体包括:
下载子模块 841, 用于根据模式选择模块 82 的选择结果获取相对应的 数据流;
缓存子模块 842, 用于根据信息获取模块 841所获取的判断结果对数据 流进行缓存。
如图 9所示, 为本发明所提供的一种基于点对点 P2P的媒体播放系统 的拓扑示意图, 其中左边部分为收看直播节目的节点, 右边部分为点播模式 及闲置状态节点。
实线连接了直播拓扑, 虚线连接了与点播有关的节点, 构成了点播拓扑 网络。
节点 E、 F、 G在系统中, 有双重角色: 自身的应用为直播模式, 处在 直播模式的网络拓扑中; 其磁盘缓存的数据, 被点播模式的节点利用, 因而 在点播拓扑中也扮演供流的角色。
节点 A、 B、 C、 D 以直播模式收看节目, 一般来说, 是因为首次进入 系统, 其磁盘缓存为空, 没有数据块可供点播利用, 因而只存在直播应用 中, 但其已经向该节目的点播 SN进行注册, 一旦缓存数据块下载完成即进 行汇报, 加入点播拓扑。
节点 I、 J表示点播拓扑中的 SN, 节点 0为没有参与节目收看的闲置节 点, 但是其磁盘有缓存数据, 进入了点播拓扑结构。 节点 H、 K、 L、 M、 N 表示点播模式中的普通节点。
节点 H、 I、 J、 K、 L、 M、 N以点播模式收看节目, 有三种方式获得视 频流: 从点播 ES获取; 从点播拓扑结构 (点播模式 (如 H) , 或者直播模 式 (如 F) ) 的节点中获取; 也有可能从并没有收看节目, 但是其磁盘缓存 中有数据的闲置节点 (如 0) 获取。
基于上述的网拓扑结构, 可以实现节点的直播模式与点播模式的切换: 在图 9中, 处于直播模式的 A节点, 一段时间后缓存了视频数据, 加 入点播拓扑, 以内容提供者的身份为节点 H和 L供流, 而自身仍然在以直 播模式收看节目, 在直播中的拓扑保持不变, 如图 10所示。
图 9中的节点 F, 此时节目收看模式由直播切入点播, 这时, 它需要从 直播拓扑中退出, 只存在于点播拓扑图中, 变成点播节点。 退出直播拓扑, 必然导致拓扑图的节点关系变化, 这时直播拓扑需要感知 F的退出对其它节 点的影响, 并迅速采取措施: 比如 F从直播拓扑中的退出会导致 G在直播 拓扑中的孤立, 无法获取直播视频流。 这时, G与直播拓扑中的其它节点关 联, 比如和节点 A建立连接, 保证数据获取的正常进行, 如图 11所示。
具体的, 如图 12所示, 为本发明实施例所提出的技术方案的详细流程 图,
节点进入系统, 通过 RRS登录网络;
节点判断自身是否有相关内容的缓存, 如果有, 则获取与缓存内容相应 的 VOD— ES, 并进一歩通过 VOD— ES获取相对应的 SN, 向该 SN登记缓存 内容的信息;
登记完成后, 或判断自身无相关内容的缓存时, 节点选择希望获取的节 目目内内容容,, 并并决决定定是是通通过过直直播播模模式式或或点点播播模模式式进进行行上上述述内内容容的的获获取取;;
如如果果选选择择直直播播模模式式,, 则则从从 RRRRSS获获取取相相应应的的 LLiivvee—— EESS、、 VVOODD—— EESS、、 邻邻居居节节 点点信信息息以以及及是是否否缓缓存存内内容容的的标标识识,, 然然后后,, 通通过过上上述述信信息息获获取取数数据据流流;;
如如果果选选择择点点播播模模式式,, 则则从从 RRRRSS获获取取相相应应的的 VVOODD—— EESS、、 邻邻近近节节点点的的集集合合 55 信信息息以以及及是是否否缓缓存存内内容容的的标标识识,, 然然后后,, 通通过过上上述述信信息息获获取取数数据据流流;;
当当获获取取足足够够的的数数据据内内容容后后还还包包括括根根据据上上述述是是否否缓缓存存内内容容的的标标识识进进行行是是否否 缓缓存存的的判判断断,, 具具体体包包括括是是否否缓缓存存文文件件级级内内容容的的判判断断,, 如如果果进进行行文文件件级级缓缓存存,, 则则存存储储相相应应的的文文件件级级内内容容,, 如如果果不不进进行行文文件件级级缓缓存存,, 则则可可以以进进一一歩歩判判断断是是否否 进进行行内内容容分分块块级级的的缓缓存存,, 如如果果缓缓存存,, 则则缓缓存存该该内内容容分分块块,, 如如果果不不缓缓存存,, 则则放放 1100 弃弃缓缓存存该该内内容容分分块块,, 当当节节点点进进行行了了缓缓存存之之后后可可以以进进一一歩歩作作为为点点播播的的内内容容源源,, 为为其其他他选选择择点点播播的的节节点点提提供供内内容容。。
同同时时,, 在在本本流流程程中中还还包包含含直直播播模模式式与与点点播播模模式式之之间间的的切切换换。。 为为方方便便说说明明,, 本本发发明明实实施施例例通通过过将将全全过过程程划划分分为为五五个个部部分分,, 并并结结合合附附图图 进进行行说说明明,, 具具体体描描述述如如下下::
1155 第第一一部部分分,, 如如图图 1133所所示示,, 为为节节点点登登录录流流程程,, 其其中中,, 节节点点进进入入系系统统,, 首首 先先和和 RRRRSS取取得得联联系系登登录录网网络络。。 如如果果是是第第一一次次打打开开终终端端使使用用系系统统,, 其其磁磁盘盘缓缓 冲冲为为空空,, 则则不不向向 RRRRSS汇汇报报数数据据,, 只只登登录录。。 否否则则,, 向向 RRRRSS汇汇报报数数据据,, RRRRSS返返 回回与与磁磁盘盘所所缓缓存存内内容容相相对对应应的的 VVOODD—— EESS信信息息,, 继继而而获获得得对对应应的的 SSNN,, SSNN登登 记记该该节节点点所所缓缓存存的的内内容容分分块块信信息息。。
2200 需需要要进进一一歩歩指指出出的的是是,, 有有可可能能节节点点只只走走到到这这一一歩歩,, 即即只只打打开开终终端端,, 但但不不 再再继继续续选选择择直直播播或或者者点点播播模模式式。。 这这种种情情况况尤尤其其适适应应于于机机顶顶盒盒应应用用,, 这这样样,, 节节 点点所所拥拥有有的的磁磁盘盘缓缓存存文文件件就就能能被被拓拓扑扑中中的的点点播播节节点点利利用用,, 为为点点播播节节点点供供流流。。
相相应应的的,, 图图 1133所所示示的的是是用用户户登登录录时时的的流流程程示示意意图图,, 与与后后续续用用户户是是进进入入 直直播播、、 点点播播还还是是保保持持现现有有闲闲置置状状态态无无关关,, 具具体体包包括括以以下下歩歩骤骤::
Figure imgf000017_0001
歩歩骤骤 SS11330022、、 节节点点从从 RRRRSS登登录录、、 汇汇报报所所缓缓存存内内容容数数据据。。 歩骤 S1303、 RRS返回一系列与该缓存内容有关的 VOD— ES。 如果节点磁盘没有缓存数据, 则 RRS只用于登录, 不会返回 VOD— ES 自 歩骤 S1304、 节点获得 VOD— ES信息之后, 与 VOD— ES进行连接。 歩骤 S1305、 VOD— ES返回每一个内容的 SN信息。
歩骤 S1306、 节点再向 SN汇报内容分块信息。
歩骤 S1307、 SN据此修改其内部数据结构 Reglnfo, 记录新加入节点及 其内容分块信息。
歩骤 S1308、 返回登记结果。
其中, 不同的内容可能登记在同一个 SN, 也可能在不同的 SN中, 且
VOD ES也可以作为一个 SN。
第二部分, 如图 14所示, 为直播模式的操作流程, 在直播模式中, 节 点与 RRS 取得联系, 获得 Live— ES 信息以及邻居节点的信息, 之后与 Live— ES和邻居节点之间建立连接, 完成了节点加入直播拓扑。 同时从 RRS 上获取直播内容的 VOD— ES, 并与 VOD— ES建立连接获取 SN信息;
然后, 从这些直播邻居节点获取或者接收直播数据流。 其中, RRS根 据该节目的热度反馈是否进行数据存储, 决定该新加入节点是否对获取的数 据流进行缓存, 如一个新节点加入该节目时, 如果当前正在使用该内容的节 点用户多于设定的文件级阈值 N1 , 那么就返回给该节点一个存储标志信息 Flag=0 (不缓存) , 否则返回 Flag=l (缓存) 。
当直播节点获取到一部分完整的内容分块的时候, 联系 SN进行该内容 分块的登记 (SN设定其管理的域内该内容的内容分块级阈值 N2, 如果该部 分内容分块 BlockID对应的 PeerNum大于内容分块级阈值 N2, 那么返回不 需要存储该内容分块, Flagl = 0, 否则, Flagl = l ) 。
节点在后续节目收看中, 会获得节目的新的下载文件, 因此, 节点定期 检测是否有内容分块 (如 4M为一 Block) 已经下载完成, 向 SN登记汇报 信息, 确定是否对下载的内容分块进行磁盘存储。 此时, 直播模式的节点如 果缓存了新内容, 可以加入该内容的点播拓扑, 为点播节点供流。
处于直播状态的节点, 可能处于双重结构中: 在直播拓扑结构中, 自己 受惠也服务其它直播节点; 在点播拓扑中, 提供已缓存的数据给点播模式的 节点。 如果点播模式的某节点缓存了某直播节目的内容, 该点播模式的节点 也可以作为直播模式的节点, 直播相对点播来说, 拓扑结构和供流都比较稳 定, 直播的质量可以得到保障, 也可以不需要该点播模式的节点来为收看直 播的节点来提供流支持。 因而登录的闲置节点也可以不考虑加入直播拓扑。
具体的, 直播模式信令交互流程如图 14所示, 包括以下歩骤: 歩骤 S1401、 节点选择内容进入直播模式。
歩骤 S1402、 节点与 RRS建立连接, 进行交互。
歩骤 S1403、 从 RRS 处获取边缘服务器信息 (包括该内容对应的 Live— ES和 VOD— ES) 及其邻居节点。
RRS根据该节目的直播拓扑情况, 决定是否该新加入节点对直播内容 进行缓存 (即文件级的缓存) 。
歩骤 S1404、 与 Live— ES建立连接, 进行交互。
歩骤 S1405、 从 Live— ES处获取快速视频数据缓冲, 该歩骤为可选歩 骤。
歩骤 S1406、 与该内容的 VOD— ES建立连接, 进行交互。
歩骤 S1407、 获得该内容 SN信息。
歩骤 S1408、 与 SN信息中指出的 Peers进行交互, 获得需要内容数 据。
节点加入直播拓扑中的适当位置, 与邻居节点建立连接观看节目, 从邻 居节点或 Live— ES处下载数据。
歩骤 S1409、 检测是否已经下载了一部分完整的内容分块, 如果是则登 记该内容分块, 进入歩骤 S1410, 否则, 返回歩骤 S1408, 继续获取数据。 歩骤 S1410、 向 SN登记文件块信息。 SN根据文件缓存结果和其所管 理域内该内容分块的存储情况, 决定该块是否缓存 (此处为针对内容分块的 缓存, 如果文件级缓存判断结果为真, 则此处不用判断, 直接存储并向 SN 登记) 。
歩骤 S1411、 SN修改其数据结构 Reglnfo, 保持数据同歩更新。
歩骤 S1412、 返回登记结果。
进一歩需要指出的是, 用户登记和获取数据是同歩的, 只有到最后完成 整个内容下载的时候, 上述的整个流程才结束。
RRS交互返回给直播用户的数据结构如图 15所示:
其中, VOD— ES表示该直播节目的点播边缘服务器;
Live— ES表示该直播节目的直播边缘服务器;
Flag表示是否对该节目进行缓存的标志位, 1 表示存储, 0表示不存 储。
NeighborList表示该节目在直播拓扑中的邻居节点; 其中该 List中存在 一个数据结构, PeerlD表示节点在该系统中的唯一标识, PeerAddr表示该 节点的 IP地址; Relation表示该节点与请求节点之间的关系, 包括该节点是 请求节点的祖父节点、 父亲节点、 孩子节点, 孙子节点。 请求节点只连接父 亲节点和孩子节点。 从父亲节点获取数据, 并把数据传给孩子节点。 当其中 有一类节点掉线, 那么存在其他节点通知并获取替换的该类节点。
第三部分, 如图 16所示, 为点播模式的操作流程。
节点从 RRS上获取的是节点所需要的同一节目点播时间点临近的节点 信息。 且根据系统状况, 判断是否该加入节点对下载数据进行磁盘存储, 即 文件级的存储。 如果当前正在使用该内容的节点用户多于设定的文件级阈值 N1 , 那么就返回给该节点一个存储标志信息 Flag=0 (不存储) , 否则返回 Flag=l (存储) 。
节点向 VOD ES发送获取内容的请求, 得到与请求内容相关的 SN信 息。 同时, 通过 VOD— ES获取快速缓存数据 (该歩骤为可选歩骤) , 并与 获取的节点选择性的建立连接, 获得内容数据。
如果节点初次加入该内容的点播系统或者当前拥有的可用节点不足, 则 向 SN发起节点查询请求, 取得节点, SN根据每一个节点在本地登记的状 态, (点播模式、 直播模式或者闲置状态) , 根据策略: 优先选择闲置状态 的节点, 然后是点播模式的节点, 最才是直播模式节点, 反馈给节点——选 择的原因: 闲置节点拥有足够多的空闲资源, 直播节点在拓扑架构中稳定持 续获取 /传递数据, 消耗带宽。
当点播节点获取到一部分完整的内容分块的时候, 联系 SN进行该内容 分块登记 (SN设定其管理的域内该内容的内容分块级阈值为 N2, 如果该部 分内容分块 BlockID对应的 PeerNum大于 N2, 那么返回不需要存储该块, Flagl =0, 否则, Flagl = l ) 。
具体的, 点播模式流程示意图如图 16所示, 包括以下歩骤:
歩骤 S1601、 用户选择点播节目进入点播模式。
歩骤 S1602、 首先节点与 RRS取得联系。
歩骤 S1603、 从 RRS处获取 VOD— ES信息, 并得到元数据信息、 目前 使用该内容的节点数量 (或者标识是否进行该节目内容文件级缓存) 、 以及 临近播放点节点的信息。
歩骤 S1604、 与 VOD— ES建立连接, 进行交互。
歩骤 S1605、 获取该节目内容快速数据缓冲 (为可选) 和 SN的信息。 歩骤 S1606、 与 SN建立连接。
歩骤 S1607、 从 SN获取可连接节点列表, 以供建立连接。
歩骤 S1608、 与 SN信息中指出的 Peers进行交互, 获得需要的数据。 节点从获知的节点列表中选择的节点或者 VOD— ES , 建立连接下载数 据, 这时 SN, 可以依照节点附带的标志位信息作为参考, 将下行带宽比较 大的节点返回。 歩骤 S1609、 检测是否已经下载了一部分完整的内容分块, 如果是则登 记该内容分块, 进入歩骤 S1610, 否则, 返回歩骤 S1608, 继续获取数据。
歩骤 S1610、 一旦内容分块完成下载, 向 SN进行内容登记, SN根据 其所管理域内该内容分块的存储情况, 决定是否该块是否缓存 (如果文件级 缓存判断结果为真, 则此处可以不用判断, 直接存储并向 SN登记) 。
歩骤 S1611、 SN修改其内部数据结构, 保持更新。
歩骤 S15612、 返回登记结果。
RRS交互返回给点播用户的数据结构如表 6所示:
表 6 点播模式下 RRS反馈的数据结构列表
VOD ES Playpoint Nodes Flag 其中, VOD— ES: 表示该节目的点播边缘服务器;
Playpoint Nodes: 表示该节点即将要播放的时间点附近的节点;
Flag: 表示是否对节目进行缓存的标志位, 0表示不存, 1表示进行缓 第四部分, 如图 17所示, 为是否缓存内容的判断流程。
不管是在直播还是在点播中, 收看热门节目的节点都会很多。 在节目内 容磁盘缓存这个问题上, 有一个比较判断过程。 没有必要对所有节点收看的 每一个节目都作为最新的内容存储起来, 因为磁盘空间有限, 新存储内容会 导致以前的内容被替换掉, 而且拓扑中的每个节点或者绝大多数节点都存储 同一个内容同样没有必要。
具体的比较判断过程如图 17所示, 包括以下歩骤:
歩骤 S1701、 设定业务需要的缓存节点数量为文件级阈值, 设定业务需 要的缓存内容分块数量为内容分块级阈值。
歩骤 S1702、 比较 RRS 中记录的已有的缓存节点是否高于文件级阈 值。 当 RRS 中记录的已有的对直播业务或点播业务对应的数据流进行缓存 的节点数量低于文件级阈值时, 转入歩骤 S1703 ;
当 RRS 中记录的已有的对直播业务或点播业务对应的数据流进行缓存 的节点数量高于文件级阈值时, 转入歩骤 S1704。
歩骤 S1703、 判断对直播业务或点播业务对应的数据流进行文件级缓 存。
判断进行文件级缓存时, 肯定对当前内容分块进行磁盘缓存。 此时, 节 点每下载一个文件块, 放在内存中, 不立即写入磁盘, 向 SN登记, 待到 SN返回结果后, 将内容从内存写入磁盘, 默认情况下是写成功, 不再进行 交互 ·' 如果没有写成功, 则节点向 SN发出消息, SN将相应的内容分块的 统计信息进行修改。
歩骤 S1704、 不进行文件级缓存, 比较 SN中记录的进行缓存的内容分 块数量是否高于内容分块级阈值。
节点向该内容的点播 SN进行登记 (以块为单位) , SN返回登记结 果, 显示其管理的节点中拥有的该内容分块信息, 节点根据 SN返回的结果 决定对下载的块是否缓存, 具体为:
当 SN中记录的进行缓存的内容分块数量低于内容分块级阈值时, 转入 歩骤 S1705 ;
当 SN中记录的进行缓存的内容分块数量高于内容分块级阈值时, 转入 歩骤 S 1706。
歩骤 S1705、 判断对当前内容分块进行内容分块缓存。
歩骤 S1706、 判断对该数据流和当前内容快均不进行缓存。
即当文件级的比较 (拓扑中该节目收看节点) 超过门限值且微观的内容 分块比较 (该文件块在 SN管理的域内的存储量) 超过门限值, 两个条件都 成立时, 不对文件及内容分块进行存储。
第五部分, 如图 18所示, 为通过直播节点拖动, 实现直播模式到点播 模式切换的操作流程。
节点播放节目过程中可能会随时的切换节目或者切换模式: 直播节点拖 动进入点播模式、 点播节点拖动或者切换节目。 对于由直播模式切换入点播 模式, 节点从直播拓扑中退出, 保持其在点播拓扑中的位置, 再向点播内容 的 Vod— ES获取 SN信息和快速数据缓冲, 从 SN节点获取拖动点的可连接 节点集合, 后续操作与进入点播的操作相同。
节点由直播模式切入点播模式, 其视频流的获取模式一般来说会发生变 化。 这时, 节点需要从直播拓扑图退出, 加入点播拓扑图; 或者保留在直播 拓扑中的位置, 避免直播拓扑结构的频繁变化, 减少扰动。 后种情况下, 点 播节点在直播拓扑中, 作为中间节点转发视频流。 优点是, 稳定直播拓扑结 构, 避免退出操作; 缺点是直播拓扑结构可能变得异常庞大, 许多中间节点 并不直接需要直播模式提供播放流, 因此, 我们选择将节点从直播拓扑中退 出, 如图 11所示。 一般说来, 一个节点进入点播模式后, 在某个时间后与 直播同歩的概率极小, 可以不考虑某节目点播节点后续进入该节目直播模式 的情况。
节点通过拖动直播点进入点播模式信令交互示意图如图 18所示, 从直 播模式切入点播模式, 该节点需要从直播拓扑中退出, 并获取拖动后的播放 时间点的节点信息, 具体包括以下歩骤:
歩骤 S1801、 用户在直播模式下对直播点进行拖动。
歩骤 S1802、 向 RRS登记退出直播模式, 将要切入点播模式和切入的 播放点, 这时节点通知 RRS退出直播列表, 进入点播列表, RRS据此更改 其保存的数据, 符合节点当前的实际情况。
节点向 RRS发送的数据结构如表 7所示:
表 7 直播至点播模式切换过程中节点向 RRS发送的数据结构列表
Figure imgf000024_0001
其中, ContentID表示节目内容 ID; PeerlD表示节点 ID;
SwitchFlag表示节点从直播模式切入点播模式的标志位;
SwitchPoint表示节点切入点播后的播放时间点。
歩骤 S1803、 从 RRS处返回拖动后的播放时间点的节点信息, 可供建 立连接时选择节点。
歩骤 S1804、 查看本地是否拥有足够的数据, 如果没有那么就节点向 VOD— ES请求快速数据缓冲。
歩骤 S1805、 VOD— ES返回数据给节点, 以减小拖动延迟。
歩骤 S1806、 节点向 SN请求登记有请求数据的节点。
歩骤 S1807、 从 SN获取节点列表。
歩骤 S1808、 与 Peers进行交互, 获得需要的数据。
歩骤 S1809、 检测是否已经下载了一部分完整的内容分块, 如果是那就 登记该内容分块, 进入歩骤 S1810 , 否则, 返回歩骤 S1808 , 继续获取数 据。
歩骤 S1810、 待到某些内容分块下载完成, 向 SN登记信息 SN根据其 所管理域内该内容分块的存储情况, 决定是否该块是否缓存。 (如果文件级 缓存 Num— File<Nl判断为真, 则不用判断, 直接存储, 向 SN登记) 。
歩骤 S1811、 SN修改其数据结构 RegInfo。
歩骤 S1812、 返回登记结果。
进一歩需要指出的是, 对于原来的直播拓扑, 即将退出的节点可以有两 种选择: 主动发起退出请求, 比如向直播 ES或者其邻居节点发起退出通 知, 这样, 自组织网络可以主动应对拓扑结构的变化; 另一种方法是被动 的, 不主动通知其在直播拓扑中的节点, 而是直接离开, 由其邻居节点探测 到他的离开, 再采取策略, 自适应。
其中, 第一种退出方案的流程示意图如图 19所示, 与直播 ES举行交 互, 通知其即将切入点播模式, 包括以下歩骤: 歩骤 S1901、 用户选择切换模式, 进入点播。
歩骤 S1902、 节点退出时主动发出通知, 通知 Live— ES。
歩骤 S1903、 Live— ES向其它节点发出通知。
歩骤 S1904、 该网络自组织动态调整, 以应对网络中的节点变化。
另一方面, 除了上述的直播至点播的模式切换过程, 本发明技术方案还 包括其他的切换流程, 具体为:
1、 直播节点切换节目流程:
直播节点切换节目的过程与第一次选择节目的过程相似, 只是要保持其 在点播拓扑中的位置, 通知相应的 SN修改节点状态信息, 且退出其在上一 个节目中的直播拓扑。
2、 点播节点切换流程:
点播节点可切换进入直播模式、 切换节目进入点播或直播。
切换进入直播模式, 与第一次进入直播模式相同, 其在点播拓扑中的位 置仍然要保持, SN修改节点的状态信息, 进入新节目的直播拓扑; 切换节 目进入点播或者直播, 与第一次进入点播和直播的交互是相同的, 其在原来 点播拓扑图的位置也要保持, 并通知具有缓存数据登记的 SN修改节点的状 态。
上述的切换过程同样属于本发明的保护范围。
本发明实施例的技术方案具有以下优点, 因为充分利用了直播和点播视 频服务的特点, 将二者进行融合, 实现了直播到点播的自由切换, 同时改进 磁盘缓存方法, 使节目资源均衡分布并增加可连接节点, 并将用户节点磁盘 缓存的数据用于点播, 此外, 系统根据资源分布情况, 判断是否对当前收看 节目是否进行缓存, 从而, 在保证有足够内容用于网络应用的情况下, 避免 了过多重复存储内容而造成浪费, 提高了网络资源利用率, 改善了用户使用 体验。
通过以上的实施方式的描述, 本领域的技术人员可以清楚地了解到本发 明可以通过硬件实现, 也可以借助软件加必要的通用硬件平台的方式来实现 基于这样的理解, 本发明的技术方案可以以软件产品的形式体现出来, 该软 件产品可以存储在一个非易失性存储介质 (可以是 CD-ROM, U盘, 移动 硬盘等) 中, 包括若干指令用以使得一台计算机设备 (可以是个人计算机, 服务器, 或者网络设备等) 执行本发明各个实施例所述的方法。
以上所述仅是本发明的优选实施方式, 应当指出, 对于本技术领域的普 通技术人员来说, 在不脱离本发明原理的前提下, 还可以做出若干改进和润 饰, 这些改进和润饰也应视本发明的保护范围。

Claims

权利要求书
1.一种基于点对点 P2P的媒体播放方法, 包括以下歩骤:
登录网络;
选择直播业务或点播业务, 并接收是否对所述直播业务或点播业务对应 的数据流进行缓存的判断结果;
根据所述选择结果获取所述对应的数据流, 并在所述判断结果为是时, 对所述数据流进行缓存;
所述缓存的对应数据流分别作为点播业务或直播业务的数据源提供给点 播节点或直播节点。
2. 如权利要求 1 所述的基于 P2P的媒体播放方法, 所述登录网络之 m , 还包括:
由核心服务器对所述直播业务或点播业务的内容源进行统一编码的处 理, 并将所述处理后的内容源发送给对应的直播业务边缘服务器 Live— ES或 点播业务边缘服务器 VOD— ES, 用户通过所述直播业务边缘服务器 Live— ES 选择直播业务, 通过所述点播业务边缘服务器 VOD—ES选择点播业务。
3.如权利要求 1所述的基于 P2P的媒体播放方法, 所述登录网络, 具 体包括:
登录用户请求路由系统 RRS;
判断本地磁盘是否存在缓存数据;
当存在所述缓存数据时, 从所述 RRS获取所述缓存数据对应的点播业 务信息, 并根据所述点播业务信息进行所述缓存数据的信息登记。
4.如权利要求 3所述的基于 P2P的媒体播放方法, 所述缓存数据对应 的点播业务信息, 具体包括:
所述缓存数据对应的 VOD— ES和超级节点 SN的信息;
所述缓存数据的信息登记为向所述 SN进行信息登记。
5.如权利要求 2所述的基于 P2P的媒体播放方法, 所述选择直播业务 具体为:
获取所述直播业务对应的 Live— ES信息、 VOD— ES信息和直播邻居节点 自
6.如权利要求 5所述的基于 P2P的媒体播放方法, 所述根据所述选择 结果获取所述对应的数据流, 并在所述判断结果为是时, 对所述数据流进行 缓存具体为:
通过所述 VOD— ES获取所述直播业务对应的 SN;
从所述 Live— ES或所述直播邻居节点下载所述直播业务对应的数据流; 向所述 SN进行所述直播业务的内容登记。
7. 如权利要求 1 所述的基于 P2P的媒体播放方法, 所述选择点播业 务, 并接收是否对所述点播业务对应的数据流进行缓存的判断结果, 具体 为:
获取所述点播业务对应的 VOD— ES信息、 邻近所述点播业务播放点的 播放节点信息和是否缓存所述点播业务对应的数据流的信息。
8.如权利要求 7所述的基于 P2P的媒体播放方法, 所述根据所述选择 结果获取所述对应的数据流, 并在所述判断结果为是时, 对所述数据流进行 缓存, 具体为:
通过所述 VOD— ES获取所述点播业务对应的 SN和数据;
向所述 SN请求可连接的节点集;
从所述 VOD— ES或所述节点集中的节点下载所述点播业务对应的数据 流;
向所述 SN进行所述点播业务的内容登记。
9.如权利要求 6或 8所述的基于 P2P的媒体播放方法, 所述对所述直播 业务或点播业务对应的数据流进行缓存的判断, 具体为:
判断所述直播业务或者所述点播业务对应的数据流内容缓存节点数量是 否低于设置的文件级阈值, 如果低于, 则对所述直播业务或者所述点播业务 对应的数据流进行缓存。
10.如权利要求 9所述的基于 P2P的媒体播放方法, 进一歩包括: 判断所述直播业务或者所述点播业务对应的数据流的内容分块的缓存节 点数量是否低于设置的内容分块级阈值, 如果低于, 则对所述直播业务或者 所述点播业务对应的数据流进行缓存。
11.如权利要求 1所述的基于 P2P的媒体播放方法, 还包括:
当所选择业务为直播时, 拖动播放点;
在所述播放点被拖动后, 向用户请求路由系统 RSS登记, 退出所述直 播模式;
从所述 RRS获取点播节点信息;
通过所述 VOD— ES获取所述点播业务对应的超级节点 SN进行点播; 向所述 SN请求可连接的节点集;
从所述 VOD— ES或所述节点集中的节点下载所述点播业务对应的数据 流;
向所述 SN进行所述点播业务的内容登记。
12.如权利要求 11所述的基于 P2P的媒体播放方法, 进一歩包括: 向所述 RRS获取是否缓存所述点播业务对应的数据流的判断结果; 当判断结果为是时, 向所述 SN请求可连接的节点集;
从所述 VOD— ES或所述节点集中的节点下载所述点播业务对应的数据 流;
向所述 SN进行所述点播业务的内容登记。
13.—种节点, 包括:
登录模块, 用于登录网络;
模式选择模块, 用于选择直播业务或点播业务;
信息获取模块, 用于接收所述模式选择模块所选择的直播业务或点播业 务所需的网络信息和是否对所述直播业务或点播业务对应的数据流进行缓存 的判断结果;
存储模块, 用于根据所述模式选择模块的选择结果获取所述数据流, 并 根据所述信息获取模块所获取的判断结果为进行缓存时对所述数据流进行缓 存。
14.如权利要求 13所述的节点, 所述登录模块, 具体包括:
缓存判断子模块, 用于判断本地是否存在缓存数据;
登记子模块, 用于当所述缓存判断子模块判断本地存在缓存数据时, 获 取所述缓存数据对应的点播业务信息, 并根据所述点播业务信息进行所述缓 存数据的信息登记。
15.如权利要求 13所述的节点, 所述存储模块, 进一歩包括: 下载子模块, 用于根据所述模式选择模块的选择结果获取所述数据流 缓存子模块, 用于根据所述信息获取模块所获取的判断结果为进行缓存 时对所述数据流进行缓存。
16.—种用户请求路由系统 RRS, 包括:
用户管理模块, 用于管理节点信息;
拓扑管理模块, 用于管理系统内直播和点播拓扑结构信息;
服务器管理模块, 用于管理各边缘服务器的信息。
17.如权利要求 16所述的 RRS , 所述用户管理模块, 具体包括: 判断子模块, 用于判断直播业务或者点播业务对应的数据流内容缓存节 点数量是否低于设置的文件级阈值。
18.如权利要求 16所述的 RRS , 所述拓扑管理模块, 具体包括: 直播拓扑管理子模块, 用于管理直播业务对应的拓扑结构信息; 点播拓扑管理子模块, 用于管理点播业务对应的拓扑结构信息。
19.一种核心服务器 CS, 包括:
信息索引模块, 用于对所述内容源进行元数据提取, 生成索引信息; 内容分块模块, 用于对所述内容源进行分块, 确定编码格式; 内容分发模块, 用于将所述信息索引模块生成的索引信息和所述内容分 块模块分块的内容分发到相应的边缘服务器。
20.—种直播业务边缘服务器 Live— ES, 包括:
内容管理模块, 用于管理本地存放的数据;
内容通信模块, 用于获取本地需要的内容, 并处理接收的请求; 内容分块管理模块, 用于所述获取的内容的进行分块编码。
21.—种点播业务边缘服务器 VOD— ES , 包括:
内容管理模块, 用于管理本地存放的数据;
内容通信模块, 用于获取本地需要的内容, 并处理接收的请求;
SN管理模块, 用于根据所述内容管理模块所管理的数据, 管理所述数 据相对应的超级节点 SN;
簇管理模块, 用于对接入的节点进行 SN选择与注销。
22.—种超级节点 SN, 包括:
节点状态记录模块, 用于记录域内的各节点的状态信息;
判断模块, 用于根据所述节点状态记录模块所记录的域内各节点状态信 息判断直播业务或者点播业务对应的数据流的内容分块的缓存节点数量是否 低于设置的内容分块级阈值。
23.一种基于 P2P的媒体播放系统, 包括核心服务器 CS和至少一个直 播业务边缘服务器 Live— ES、 点播业务边缘服务器 VOD— ES、 用户请求路由 系统 RRS、 超级节点 SN和节点:
所述 CS , 用于对内容源进行编码处理, 并将所述处理后的内容源发送 给对应的 Live— ES或 VOD— ES;
所述 Llve— ES, 用于向所述 CS获取直播业务所需的数据流并提供给所 述节点;
所述 VOD— ES, 用于向所述 CS获取点播业务所需的数据流并提供给所 述节点; 所述 RRS, 用于管理网络中的所述 Live— ES、 VOD— ES和节点; 所述 SN, 用于管理域内各节点和内容;
所述节点, 用于获取、 传输和存储所述直播业务或点播业务所对应的数 据流。
PCT/CN2009/070375 2008-05-20 2009-02-06 一种基于p2p的媒体播放方法、装置和系统 WO2009140868A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP09749411.6A EP2288085B1 (en) 2008-05-20 2009-02-06 P2p based method, device and system for playing media
US12/950,778 US9497035B2 (en) 2008-05-20 2010-11-19 Method, device, and system for playing media based on P2P

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN200810097892.6 2008-05-20
CN2008100978926A CN101588468B (zh) 2008-05-20 2008-05-20 一种基于p2p的媒体播放方法、装置和系统

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US12/950,778 Continuation US9497035B2 (en) 2008-05-20 2010-11-19 Method, device, and system for playing media based on P2P

Publications (1)

Publication Number Publication Date
WO2009140868A1 true WO2009140868A1 (zh) 2009-11-26

Family

ID=41339753

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2009/070375 WO2009140868A1 (zh) 2008-05-20 2009-02-06 一种基于p2p的媒体播放方法、装置和系统

Country Status (4)

Country Link
US (1) US9497035B2 (zh)
EP (1) EP2288085B1 (zh)
CN (1) CN101588468B (zh)
WO (1) WO2009140868A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103747285A (zh) * 2013-12-27 2014-04-23 乐视网信息技术(北京)股份有限公司 一种节目播放方法和服务端、客户端

Families Citing this family (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102118405B (zh) * 2009-12-31 2014-07-30 比亚迪股份有限公司 一种应用于实时视频数据传输的p2p网络系统
CN102307218B (zh) * 2011-03-15 2014-04-16 陈建国 多媒体电话p2p点播的流媒体数据请求传输方法
US20120297405A1 (en) * 2011-05-17 2012-11-22 Splendorstream, Llc Efficiently distributing video content using a combination of a peer-to-peer network and a content distribution network
US9461759B2 (en) * 2011-08-30 2016-10-04 Iheartmedia Management Services, Inc. Identification of changed broadcast media items
CN103051979B (zh) * 2011-10-13 2017-08-08 南京中兴新软件有限责任公司 流媒体处理方法及系统
CN103167358B (zh) * 2011-12-09 2017-01-11 深圳市快播科技有限公司 一种机顶盒、媒体播放处理及媒体恢复播放方法
CN102917028B (zh) * 2012-09-26 2016-02-03 深圳好视网络科技有限公司 网络视频直播的缓存方法及装置
CN103096177B (zh) * 2012-10-11 2015-11-18 北京邮电大学 一种视频点播方法、系统、代理节点及媒体服务器
CN104298467B (zh) * 2013-07-17 2018-12-14 合一网络技术(北京)有限公司 一种p2p缓存文件管理方法和装置
CN105100887A (zh) * 2014-05-15 2015-11-25 中兴通讯股份有限公司 节目播放控制方法及装置
CN104394221B (zh) * 2014-11-28 2015-12-30 合一网络技术(北京)有限公司 利用边缘服务节点为流媒体应用进行加速处理的方法和系统
CN105100956A (zh) * 2015-08-21 2015-11-25 深圳中兴网信科技有限公司 数据获取方法与数据获取系统
CN107277561A (zh) * 2016-04-08 2017-10-20 北京优朋普乐科技有限公司 内容分发网络
CN111083094B (zh) * 2018-10-22 2022-06-07 中国移动通信有限公司研究院 一种流媒体的码流切换方法及装置、计算机存储介质
CN110366047B (zh) * 2019-06-04 2022-02-11 北京奇艺世纪科技有限公司 一种视频共享方法和装置及计算机可读存储介质
CN115022110B (zh) * 2022-08-08 2022-12-27 广州市千钧网络科技有限公司 消息分发方法、可读介质以及电子设备

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1604569A (zh) * 2004-10-29 2005-04-06 清华大学 一种鲁棒的基于点对点的流调度方法
CN1863054A (zh) * 2006-03-03 2006-11-15 华为技术有限公司 数字用户线接入复用器和流媒体数据传输系统及方法
CN1909509A (zh) * 2006-07-19 2007-02-07 华为技术有限公司 在媒体分发网络中实现视频直播的系统、方法和客户端
US20070183342A1 (en) * 2006-02-06 2007-08-09 Mediazone.Com, Inc. Peer-to-peer broadcast management system
CN101051980A (zh) * 2007-05-21 2007-10-10 华为技术有限公司 一种文件数据分发方法及相关设备
CN101068186A (zh) * 2007-06-05 2007-11-07 华为技术有限公司 一种客户端节点网络拓扑构造方法及流媒体分发系统

Family Cites Families (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5945987A (en) * 1995-05-05 1999-08-31 Microsoft Corporation Interactive entertainment network system and method for providing short sets of preview video trailers
US6314110B1 (en) * 1998-03-06 2001-11-06 Cisco Technology, Inc. Method and apparatus for distributed bandwidth allocation for a bi-directional ring media with spatial and local reuse
US20020124262A1 (en) * 1999-12-01 2002-09-05 Andrea Basso Network based replay portal
US7107606B2 (en) * 2000-08-30 2006-09-12 The Chinese University Of Hong Kong System and method for highly scalable video on demand
CA2503682A1 (en) * 2001-10-24 2003-05-15 The Fantastic Corporation Methods for multicasting content
KR20030056701A (ko) * 2001-12-28 2003-07-04 한국전자통신연구원 P2p 방식을 이용한 멀티미디어 스트리밍 장치 및 방법
AU2003239385A1 (en) * 2002-05-10 2003-11-11 Richard R. Reisman Method and apparatus for browsing using multiple coordinated device
AU2005232349B2 (en) * 2004-04-16 2010-03-25 Etiip Holdings Inc Method and apparatus for delivering consumer entertainment services accessed over an IP network
US7920572B2 (en) * 2005-09-20 2011-04-05 Cisco Technology, Inc. Modifying operation of peer-to-peer networks based on integrating network routing information
US20070130597A1 (en) * 2005-12-02 2007-06-07 Alcatel Network based instant replay and time shifted playback
US8707375B2 (en) * 2006-04-05 2014-04-22 At&T Intellectual Property I, L.P. Peer-to-peer video on demand techniques
US8209729B2 (en) * 2006-04-20 2012-06-26 At&T Intellectual Property I, Lp Rules-based content management
US8028319B2 (en) * 2006-05-31 2011-09-27 At&T Intellectual Property I, L.P. Passive video caching for edge aggregation devices
US8131971B2 (en) * 2006-06-20 2012-03-06 Patentvc Ltd. Methods and systems for push-to-storage
CN100473023C (zh) * 2006-12-12 2009-03-25 中兴通讯股份有限公司 Iptv系统冗余数据的清除方法
CN101005606B (zh) 2006-12-31 2012-07-04 华为技术有限公司 一种减少媒体播放延时的方法和装置
US8832290B2 (en) * 2007-02-23 2014-09-09 Microsoft Corporation Smart pre-fetching for peer assisted on-demand media
US8244884B2 (en) * 2007-04-11 2012-08-14 The Directv Group, Inc. Method and apparatus for file sharing between a group of user devices with crucial portions sent via satellite and non-crucial portions sent using a peer-to-peer network
CN101141490B (zh) 2007-08-03 2011-11-23 中兴通讯股份有限公司 网元地址获取方法
US7975282B2 (en) * 2007-11-01 2011-07-05 Sharp Laboratories Of America, Inc. Distributed cache algorithms and system for time-shifted, and live, peer-to-peer video streaming
US7979419B2 (en) * 2007-11-01 2011-07-12 Sharp Laboratories Of America, Inc. Distributed search methods for time-shifted and live peer-to-peer video streaming
CN101179705B (zh) * 2007-11-29 2011-04-20 中兴通讯股份有限公司 伙伴资源节点选择方法和装置
EP2073503A1 (en) * 2007-12-17 2009-06-24 Alcatel Lucent Method for distributing content data packages originated by users of a super peer-to-peer network

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1604569A (zh) * 2004-10-29 2005-04-06 清华大学 一种鲁棒的基于点对点的流调度方法
US20070183342A1 (en) * 2006-02-06 2007-08-09 Mediazone.Com, Inc. Peer-to-peer broadcast management system
CN1863054A (zh) * 2006-03-03 2006-11-15 华为技术有限公司 数字用户线接入复用器和流媒体数据传输系统及方法
CN1909509A (zh) * 2006-07-19 2007-02-07 华为技术有限公司 在媒体分发网络中实现视频直播的系统、方法和客户端
CN101051980A (zh) * 2007-05-21 2007-10-10 华为技术有限公司 一种文件数据分发方法及相关设备
CN101068186A (zh) * 2007-06-05 2007-11-07 华为技术有限公司 一种客户端节点网络拓扑构造方法及流媒体分发系统

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP2288085A4 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103747285A (zh) * 2013-12-27 2014-04-23 乐视网信息技术(北京)股份有限公司 一种节目播放方法和服务端、客户端

Also Published As

Publication number Publication date
EP2288085B1 (en) 2015-04-29
US9497035B2 (en) 2016-11-15
US20110067074A1 (en) 2011-03-17
EP2288085A4 (en) 2011-06-22
CN101588468A (zh) 2009-11-25
CN101588468B (zh) 2013-08-07
EP2288085A1 (en) 2011-02-23

Similar Documents

Publication Publication Date Title
WO2009140868A1 (zh) 一种基于p2p的媒体播放方法、装置和系统
US11539768B2 (en) System and method of minimizing network bandwidth retrieved from an external network
Deshpande et al. Streaming live media over a peer-to-peer network
US10986387B1 (en) Content management for a distributed cache of a wireless mesh network
CN100461740C (zh) 一种客户端节点网络拓扑构造方法及流媒体分发系统
EP2227016B1 (en) A content buffering, querying method and point-to-point media transmitting system
CN101729273A (zh) 一种流媒体分发系统、方法及装置
US11089103B1 (en) Content management in a distributed cache of a wireless mesh network
Shen et al. A DHT-aided chunk-driven overlay for scalable and efficient peer-to-peer live streaming
CN103096177B (zh) 一种视频点播方法、系统、代理节点及媒体服务器
CN101355468A (zh) 一种p2p流媒体信息发布的方法
WO2010133140A1 (zh) 一种内容分片的多媒体网络及其业务方法
US12250254B2 (en) System and method of minimizing network bandwidth retrieved from an external network
Pal et al. A new hybrid approach for overlay construction in p2p live streaming
KR20120064969A (ko) 비디오 청크 분포에 적응적인 푸쉬-풀 혼성 스트리밍 방법 및 장치
CN101304405B (zh) 一种基于svc的p2p流媒体传输方法
CN104661106A (zh) 一种用于智能泛在终端的分布式视频点播系统
Meskovic et al. Content delivery architectures for live video streaming: hybrid cdn-p2p as the best option
CN102571842B (zh) 一种存储内容删除方法、系统及设备
Zeng et al. Enhanced video streaming network with hybrid P2P technology
JP2009200725A (ja) 情報配信システム及び同システムにおける階層構造の形成方法及びプログラム
Lin et al. P2MCMD: A scalable approach to VoD service over peer-to-peer networks
Guo et al. P cast: P2p patching scheme for vod service
Zhang A Large-Scale P2P Based Architecture for Video on Demand Service
Lim et al. Cloud Assisted P2P Live Video Streaming over DHT Overlay Network

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 09749411

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

WWE Wipo information: entry into national phase

Ref document number: 4549/KOLNP/2010

Country of ref document: IN

Ref document number: 2009749411

Country of ref document: EP