Live streaming over P2P

Index


The problem

Video streaming is an interesting possibility offered by the availability of wide-band connections. However, transmitting high-quality video to a large number of users is not a trivial task because of the output bandwidth required to the server. An interesting solution to this problem is given by a peer-to-peer (P2P) structure where each user contributes to the video dissemination by retransmitting to other users the received data.

The application of the P2P approach to video streaming, however, is not trivial because of few problems which can be summarized in the words "a user is not a server"

  • Although a user can have enough bandwidth to receive quality video, it usually has not enough bandwidth to transmit video. In a typical P2P network (used for data download, not live streaming) the low bandwidth problem is solved by asking to each node limited portions of the files (chunks). By asking different chunks to different peers, a home user can receive data at rate that is greater than the maximum upload bandwidth of a single node. Unfortunately, in the live streaming context this approach is of limited utility, since future chunks do not exist yet and past chunks are useless.
  • We have no control on the time a user will remain on-line. A user can leave at any time (even without any warning, because of crashes) leaving the nodes which were served by the user without data. This can cause a noticeable drop in the experienced quality.
  • Malicious users could "poison" the stream by injecting fake packets. Such wrong packet would rapidly spread over the P2P network.

The solution

Most of current solutions are adapted versions of the usual P2P structure, with the stream split in several chunks. In order to gain some robustness with respect sudden node departure, robust coding techniques (mainly FEC-based ones) are typically employed. Also, the nodes are sometimes organized along parallel trees, so that even if a node stop receiving data along a tree, it will keep receiving from the other trees.

At the end of 2007 our group began investigating a different approach, suggested by our experience with multiple description coding. The basic idea is to split every packet of the content stream into a set of "fragments" (called "reduced packets") with the property that the content packet can be recovered as soon as at least R different fragments are known.

This problem sounds a lot like a "secret sharing" problem and this suggested to us the approach that we presented at the Data Compression Conference (2008)

R. Bernardini, R. Rinaldo, and A. Vitali, A reliable chunkless peer-to-peer architecture for multimedia streaming in Proc. Data Compr. Conf., (Snowbird, Utah), pp. 242-251, Brandeis University, Mar. 2008.

The nice spot of our approach is that, being chunkless, it is easier to apply in the context of live streaming than other P2P solutions based on chunky solutions.

At that time we planned to produce a multimedia viewer based on our approach. Successively we discovered that we could take a more general approach by implementing our ideas in a transposrt protocol. The result of this line of development was PPETP: a Peer-to-Peer Epi-Transport Protocol that could be described as an overlay multicast protocol based on a peer-to-peer structure.

We believe that PPETP is a very interesting solution for several reasons

  • Its chunkless nature makes it a very convenient solution for live streaming applications
  • It has been designed from the start to be used with networks of residential nodes, therefore
    • It can be used with nodes with small upload bandwidth
    • It has built-in NAT traversal features
    • It is robust with respect to data losses, both due to network congestion or sudden peer departure. (Check the DCC paper for an analysis of this)
    • It has built-in security feature. A nice side effect of the reduction procedure used in PPETP it is that it can be used to identify nodes that are trying a poisoning approach. (Check the DCC paper and the Internet Draft for more informations).
  • It is very flexible: it can be used with any network structure and it allows for several management solutions, from strongly centralized to strongly distributed.
  • In order to join a PPETP session a user just need the address of a

Current status, software and more information

Software

The development of PPETP is currently hosted as part of the project Corallo on SourceForge. The main deliverable will be an Ada library (but with a C-callable API too) implementing our protocol. We do not have yet an official release, but we plan to produce the first one pretty soon.

More information

Beside the DCC paper cited above, you can refer to the current version of the Internet Draft documenting it. Also, please refer to "Documentation" section of the site of PPETP.

Call for volunteers

Of course, since this is an Open Source project, if you are an Ada programmer and are excited by this idea, you can join us.

Applications

Besides the streaming video context where our idea were born, the same approach can be adapted to other P2P-like networks. For example, one can reuse our approach for doing data routing over ad hoc networks.