Comparison of Video File Transmission
Total Page:16
File Type:pdf, Size:1020Kb
Software engineering Thesis no: BSE-2019- 0? 2019 Comparison of Video file transmission over Dat protocol and Hypertext transfer protocol Jonathan Artback Dept. Computer Science & Engineering Blekinge Institute of Technology SE–371 79 Karlskrona, Sweden This thesis is submitted to the Department of Computer Science & Engineering at Blekinge Institute of Technology in partial fulfillment of the requirements for the degree of Bachelor of Science in Software engineering. The thesis is equivalent to 20 weeks of half-time studies. Contact Information: Author(s): Jonathan Artback E-mail: [email protected] University advisor: Dr. Ahmad Nauman Ghazi Department of Software Engineering Dept. Computer Science & Engineering Internet : www.bth.se Blekinge Institute of Technology Phone : +46 455 38 50 00 SE–371 79 Karlskrona, Sweden Fax : +46 455 38 50 57 Abstract Context. Scalability and bittrate is an large concern when build- ing infrastructure and application for video content delivery. Many research and companies have for a long time looked at peer to peer technology as a way of solving the issue by utilizing the clients capac- ity. Objectives. The first objectives is to see if Dat protocol would be a good fit for video file delivery. Comparing with the widely used HTTP too see the differences in scalability and bitrate. The challenges with implementing such a solution and tactic for the future if choosing to. Methods. In order to achieve the objectives of our research a compar- ing network experiment in similar manners and with the same client base was conducted. Conclusions. The Dat protocol show good scalability and perfor- mance especially on larger number of clients compared to HTTP. Some future works on Dat protocol such as peer-selecting and load balancing are needed before Dat can be used as protocol for video delivery on commercial sites. Keywords: P2P, Decentralized, Video, content Contents Abstract i 1 Introduction 1 1.1 Content delivery network ....................... 2 1.2Peertopeer.............................. 2 1.3 Research Aim ............................. 2 1.4 Objectives ............................... 3 1.5 Problem domain ............................ 4 1.6 Research questions and motivation ................. 5 2 Background 7 2.1TypesofP2Pnetwork........................ 8 2.2 Topology of P2P network ....................... 8 2.3 Dat protocol .............................. 8 2.3.1 Dat procedure ......................... 9 2.3.2 HTTP ............................. 10 2.4 Benefits of Peer to peer technology ................. 11 2.5 Flaws of Peer to peer technology .................. 12 ii 2.6Securityinpeertopeer........................ 12 2.7HTTPvsDat............................. 12 3 Related Work 14 4 Method 17 4.1 Research Methodology ........................ 17 4.2 Prerequisites .............................. 17 4.3 Variables ................................ 18 4.3.1 Dependent Variables ..................... 18 4.3.2 Independent Variables .................... 19 4.3.3 Extraneous Variables ..................... 20 4.4Procedure............................... 20 4.4.1 HTTP ............................. 20 4.4.2 Dat peer to peer ....................... 21 5 Results 24 6 Analysis and discussion 27 6.1 Analysis of Research Q1 ....................... 27 6.2 Analysis of Research Q2 ....................... 28 6.3 Analysis of Research Q3 ....................... 28 6.4 Discussion of Research Q1 ...................... 29 6.5 Discussion of Research Q2 ...................... 29 6.6 Discussion of Research Q3 ...................... 30 6.7 Threats to validity .......................... 31 iii 7 Conclusions and Future Work 32 7.1 Conclusion ............................... 32 7.2Futurework.............................. 33 References 34 Appendices 38 A Result of network expriement 39 iv Chapter 1 Introduction Video content delivery on sites such as YouTube, Vimeo, and Netflix is a huge part of the internet today. The volume of video content traffic on the internet just keeps growing for every year[1]. With higher video resolutions and more advanced image technologies, it is a development that won’t cease in the nearest future[2]. To keep the clients happy when doing "video content providing" consistent quality of service is very important[3]. In a regular client-server type of network, this puts huge pressure on the server to handle the massive loads. Often a form of content delivery network is used to help the server. hypertext transfer protocol(HTTP) is a very common application layer protocol and also often used for video content. When used for video content delivery it is often combined with MPEG-dash and HLS which are protocols for chunking video streams and adopting the video bandwidth to the network. A technique not covered in this thesis. 1 Chapter 1. Introduction 2 1.1 Content delivery network A content delivery network is a subset of servers located on multiple data centers. The servers fetch files from each other and cache them locally. This speeds up the experience for the end user as they can fetch from a server closer to them[4]. A CDN could also be partly supported by a network where end users can download from each other so-called peer to peer[5]. 1.2 Peer to peer Peer to peer(P2P) networks have for long times attracted large attention both in industry and Academics for various reasons. Peer to peer technology solves the scalability issue of content delivery in theory by levering the resources of the participating peers[6]. That has been proved in projects such as P2Plive where a 10 Mbps server bandwidth served 400 Kbps video streams to 1.5million users[7]. 1.3 Research Aim The aim of this report was to tell if Dat protocol can be a good replacement protocol for centralized protocols used for video streaming today most commonly Chapter 1. Introduction 3 HTTP. The issue with scalability has been a problem that has been in focus of research for a long time. It motivates me to see if with open decentralized technology can serve more clients and faster connections without added costs. Bypassing political censorship on the web is also much easier with p2p technology as there is not one but many servers. 1.4 Objectives The aim of this experiment and research is to learn more about DAT(P2P), HTTP(Centralized) and how their scalability work. Given below are the objec- tives which will help us achieve the required outcome. • To identify the differences in bandwidth when scaling the different network protocols in similar manners. • To analyze the reason for differences between the two technologies in re- spect to variables such as number of clients, network upload and download bandwidth. • To identify the possibility of using Dat as an alternative for solving scala- bility issues in content and video delivery applications compared to existing HTTP solutions. Chapter 1. Introduction 4 1.5 Problem domain Centralized client-server are often used to serve video content on the web today. A big concern with client-server is the scalability. The server needs to grow its capacity with more users. Often a CDN is used. A CDN could provide a better quality to end-users and scale pass the limits of the source server when the workload is within the provisioning limits. A centralized based CDN is expensive to deploy and maintain[8]. This type of CDN is often owned by a large cloud corporation such as AWS CloudFront. The cost of using AWS Cloudfront is $850 for 10000 users streaming 1GB(as of 2019-04-06). P2P could achieve high scalability with low server requirements. It could lower the server cost and lower the need for advertising to support the hosting of websites. It could also be a profit for the climate as servers use a lot of electricity. Chapter 1. Introduction 5 1.6 Research questions and motivation • Q1 How or will Dat get a higher maximum bitrate compared to HTTP client-server infrastructure for video content providing(Mbit/s)? Motivation: Hypertext Transfer Protocol is an Application protocol for distributed content and is part of the standardized World Wide Web[9]. Although no reliable study can show which internet protocol is the most used on internet, HTTP is a very common protocol and used for most websites today. This is the protocol used on sites such as Google, YouTube and Vimeo. A http site can be distinguished by the http:// or https:// in front of the Uniform Resource Locator(URL). https is the secure/encrypted version of http. Video streaming traffic is the biggest part of internet traffic and puts great importance on high bandwidth to delivery the videos that keep growing in quality and size. This question will give an understanding of what difference the Dat protocol will do compared to HTTP client-server system. It can also help content providers decide if a rebuild for using DAT protocol will be worth it in terms of scalability. Without considering that none of the widely used web browsers yet has implemented Dat protocol. • Q2 Can the same number of clients watch higher quality content which they can when the bitrate gets higher using Dat protocol compared to HTTP client-server infrastructure for on-demand video content providing? Motivation: This research question helps us identify the scalability differ- ences in HTTP as a centralized content providing technology and Dat as a P2P technology. It is costly to scale to large user-bases on purely centralized systems. With this question, we can identify if a Dat implementation will benefit the end users in higher video qualities on the same server hardware and network. The answer