DEV Community

Cover image for Watchit - Streaming Mechanisms
Geolffrey Mena
Geolffrey Mena

Posted on • Updated on

Watchit - Streaming Mechanisms

Hello guys, in our previous post we showed a general idea about a proof of concepts of a decentralized movies playback system. In short, it allows you to see the movies that other people share with you and that you also share with them.

If you read our previous post and tried the app, you will know that the initial version of Watchit is a desktop version, which by its nature has its limitations. To expand access to our dapp and mitigate some of these limitations, we have faced the challenge of adapting Watchit to different platforms, which brought us new challenges.

To get into context we can say that for all this magic of watching a movie on our screen to be possible; Either from a "centralized" medium or from a "decentralized" medium, streaming mechanisms are needed or, say, transmission/distribution of multimedia content without interruption for the dissemination of audio/video read more.

Watchit is no exception and since we are a decentralized app we should also keep our streaming decentralized that probably would be a big problem but hopefully and thanks to its creators, mechanisms like HLS and Dash it help us with this problem. In addition to this, we also need to have a decentralized storage that allow us to keep all this multimedia stored and avoid the need for a storage server and on the contrary obtains the multimedia from the active nodes

In the past some alternatives to decentralize information was the use of torrent technology, in a brief technical summary, the problem with this tech is "interoperability" eg. desktop nodes environment use the TCP/uTP as transport protocols, which cannot directly connect with web nodes, which in turn communicate via webRtc. In simple words, it's like wanting to send an "iMessage" and have someone respond with a "normal SMS", in a way they are different communication signals and therefore they are not compatible.

The way we found to address this problem is to use IPFS (Interplanetary File System) as decentralized storage that allows us interoperability between most devices and browsers in addition to the transmission mechanisms we are talking about today, we can support Watchit without architectures complex.

HLS and DASH are streaming mechanisms supported by Watchit and that does not require such a complex architecture. The simplicity that exists in this mechanism in terms of interoperability can be seen in the graphs below:

IPFS vs Torrent Complexity

Torrent

IPFS

More info:

Top comments (0)

Visualizing Promises and Async/Await 🤯

async await

☝️ Check out this all-time classic DEV post