The goal of this page is to give you an informal introduction to PPETP: how we developed it, what kind of problems is designed to solve, how it works and why is it so cool...
Please note: This page (as the rest of this site) is still under construction and some parts are still missing. Please, be patient...
PPETP is the acronym Peer-to-Peer Epi-Transport Protocol and it can be considered as an overlay multicast protocol based on a peer-to-peer structure. In order to understand better the peculiarities of PPETP, it is worth to tell the story behind it.
Our adventure in the field of P2P streaming started more or less at the end of 2007, when we were told about the problem of streaming good quality live video to a large number of users (the typical example given for this is the F1 race that can be seen by millions of users at the same time).
Although a large audience is what a TV producer most desires, the problem of streaming video over Internet to such a large number of user stems from the following formula
Since good quality video can require few Mbit/s of bandwidth, the total bandwidth required to stream to few millions of users can easily reach very large values (~1012 bit/s), requiring important investments to the TV producer.
This problem can repropose itself, with smaller figures, even in other contexts. Consider, for example, a small community (e.g. a political party or a fan club) that wants its own TV on Internet to send video content to the community members. If the community has 100-1000 members (that could be, for example, for a medium-large fan club), the bandwidth required to stream to all the community can reach the order of Gbit/s, that, although within current technical possibilities could be too expensive for the community.
An "easy" solution to this scalability problem would be
of a Content Delivery Network (CDN) where several
servers share the burden of serving the user community. However,
the amount of produced bandwidth remains the same, only
"spread" among different servers. Moreover, if the number
of users doubles, the number of servers must double too if the
server load must remain the same.
A more efficient solution would be the use of multicast.
Unfortunately, using IP multicast over a
distributed area (especially across different
different Autonomous systems) introduces several
technical difficulties.
An approach that is considered promising is the use of a peer-to-peer network where each user retransmits to other users the received data. With this approach (that I like to call the fire brigade principle), each user contributes to the data distribution and the server "ideally" would just need to “seed” the first few peers and the network would take care of itself.
Problem solved? Not at all! Unfortunately, residential users (the most common user in an IPTV context) have several characteristics that make P2P video distribution not trivial
The typical residential user is connected to Internet via an ADSL connection that has few Mbit/s of download band (sufficient to receive fairly good video), but only few hundreds of Kbit/s in upload. Therefore, the typical user has not enough bandwidth to retransmit the received video. |
When a user stops watching a given program and leaves the network, the data flow that the user was sending to other nodes will stop too and this can happen at anytime. Even worse, the node can suddenly crash and the nodes that were depending on it will discover about the crashed node it because they will stop receiving data. Unless suitable countermeasures are taken, this would result in a poor perceived quality, usually in the form of video “freezes”. |
The user “inject” in the stream some bogus content that could be both data that cannot be decoded or even an alternative content that the user wants to distribute. This will cause an incorrect decoding in the users receiving the bogus content. Even worst, the content will spread to the whole network carried by the P2P mechanism. |
Giving here a complete taxonomy of the available solutions for P2P streaming would bring us too far... Moreover, such a taxonomy could become obsolete very soon since streaming over P2P is currently (December 2010) a very hot topic. However, it can be said (maybe oversimplifying a little) that most of the structures for P2P streaming are inspired to P2P solutions for file sharing. In a file sharing context a file is typically partitioned in smaller units called “chunks”. A node that desires to download a specific file would search for other nodes that have portions of the desired file and ask them chunks. By asking different chunks to different peers, a node can achieve a good download speed, even if each single peer has a small upload bandwidth. Typically peers in a file-sharing P2P network exchange information about chunk availability, so that a node can find who has a given chunk.
The description above is very rough. Depending on the specific P2P system, many details can be be different. Nevertheless, the description above suffices for our goals.
The chunky approach works fine for file sharing (where the file is static) and it can be interesting for a video on demand (VOD) context, where each user keeps on its disk the files relative to previously view videos.
However, in the live streaming context the application of the chunky approach can be more problematic. Maybe one of the major difficulties is that in the case of live streaming, too old chunks are useless and future chunks do not even exist... The most intuitive solution to this problem is the use of a buffer where chunks are stored, waiting to be played. In this way the “playing instant” is an instant in the past and there is time to achieve from other peers the chuncks relative to times between the playing instant and current time. Unfortunately, this “time shift” requires a buffer filling and this causes long starting times. The startup delay problem can be reduced somehow by some “smart tricks” such as commercials, introductory tunes or variable speed playing.
The funniest part of the story is that we (the DSP group at the University of Udine) are not "network people", but "signal processing people", with a preference for video coding. At the time when we discovered about the problem of live streaming to a large audience, we were doing research about multiple description coding (MDC), a technique of robust coding that achieve robustness by splitting the multimedia content into several independent streams (known as descriptions) with a smaller bandwidth and with the property that each description can be decoded by itself to produce a low-quality version of the original content, but if one has all the descriptions can obtain a full-quality version.
When we heard about the live streaming problem, we decided to apply a principle similar to MDC: split the original multimedia stream (called content stream in PPETP jargon) into many streams (called reduced streams), where each stream requires a lower bandwidth (say, a bandwidth R times smaller) and such that the following R-recovery property holds
The tricky part is to find a way to split the original content stream so that the R-recovery property is satisfied. The default PPETP reduction scheme uses quite common an approach based on Reed-Solomon codes. If you do not know what Reed-Solomon codes are or you do not know how they can be used in a reduction scheme, I suggest you to read this.
For the sake of convenience, PPETP operates said reduction on a packet-by-packet basis, that is every content packet is processed in order to reduce its size of a factor R, so that the corresponding stream will require a bandwidth R times smaller.
This is a good place to introduce some more PPETP jargon. If a node A sends a reduced stream to a node B we will say that A is an upper peer of B and that B is a lower peer of A. This nomenclature is inspired to a picture where data flows from top to bottom.
In order to receive the content stream a node
Employing reduction functions has several interesting consequences
The reduction procedure is the original "core" of PPETP. During these years PPETP evolved and now is a fairly complete protocol with several interesting features, among which