Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

A Peer-to-Peer Simulator

5,288 views

Published on

A Peer-to-peer simulator for content-distribution networks that I developed at Darmstadt University of Technology for my bachelor's thesis.

Published in: Technology, Sports
  • You can try to use this service ⇒ www.HelpWriting.net ⇐ I have used it several times in college and was absolutely satisfied with the result.
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • You can ask here for a help. They helped me a lot an i`m highly satisfied with quality of work done. I can promise you 100% un-plagiarized text and good experts there. Use with pleasure! ⇒ www.WritePaper.info ⇐
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • Follow the link, new dating source: ❤❤❤ http://bit.ly/2F90ZZC ❤❤❤
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • Dating for everyone is here: ❶❶❶ http://bit.ly/2F90ZZC ❶❶❶
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • DOWNLOAD THIS BOOKS INTO AVAILABLE FORMAT (2019 Update) ......................................................................................................................... ......................................................................................................................... Download Full PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download Full EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download Full doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download PDF EBOOK here { https://soo.gd/irt2 } ......................................................................................................................... Download EPUB Ebook here { https://soo.gd/irt2 } ......................................................................................................................... Download doc Ebook here { https://soo.gd/irt2 } ......................................................................................................................... ......................................................................................................................... ................................................................................................................................... eBook is an electronic version of a traditional print book THIS can be read by using a personal computer or by using an eBook reader. (An eBook reader can be a software application for use on a computer such as Microsoft's free Reader application, or a book-sized computer THIS is used solely as a reading device such as Nuvomedia's Rocket eBook.) Users can purchase an eBook on diskette or CD, but the most popular method of getting an eBook is to purchase a downloadable file of the eBook (or other reading material) from a Web site (such as Barnes and Noble) to be read from the user's computer or reading device. Generally, an eBook can be downloaded in five minutes or less ......................................................................................................................... .............. Browse by Genre Available eBooks .............................................................................................................................. Art, Biography, Business, Chick Lit, Children's, Christian, Classics, Comics, Contemporary, Cookbooks, Manga, Memoir, Music, Mystery, Non Fiction, Paranormal, Philosophy, Poetry, Psychology, Religion, Romance, Science, Science Fiction, Self Help, Suspense, Spirituality, Sports, Thriller, Travel, Young Adult, Crime, Ebooks, Fantasy, Fiction, Graphic Novels, Historical Fiction, History, Horror, Humor And Comedy, ......................................................................................................................... ......................................................................................................................... .....BEST SELLER FOR EBOOK RECOMMEND............................................................. ......................................................................................................................... Blowout: Corrupted Democracy, Rogue State Russia, and the Richest, Most Destructive Industry on Earth,-- The Ride of a Lifetime: Lessons Learned from 15 Years as CEO of the Walt Disney Company,-- Call Sign Chaos: Learning to Lead,-- StrengthsFinder 2.0,-- Stillness Is the Key,-- She Said: Breaking the Sexual Harassment Story THIS Helped Ignite a Movement,-- Atomic Habits: An Easy & Proven Way to Build Good Habits & Break Bad Ones,-- Everything Is Figureoutable,-- What It Takes: Lessons in the Pursuit of Excellence,-- Rich Dad Poor Dad: What the Rich Teach Their Kids About Money THIS the Poor and Middle Class Do Not!,-- The Total Money Makeover: Classic Edition: A Proven Plan for Financial Fitness,-- Shut Up and Listen!: Hard Business Truths THIS Will Help You Succeed, ......................................................................................................................... .........................................................................................................................
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here

A Peer-to-Peer Simulator

  1. 1. Introduction Model Simulation Application Summary A Peer-to-Peer Simulator Uwe Schmidt Bachelor Thesis August 17, 2006 Uwe Schmidt: A Peer-to-Peer Simulator 1 / 28
  2. 2. Introduction Model Simulation Application Summary Outline Introduction 1 Model 2 Simulation 3 Application 4 Uwe Schmidt: A Peer-to-Peer Simulator 2 / 28
  3. 3. Introduction Model Simulation Application Summary Outline Introduction 1 Model 2 Simulation 3 Application 4 Uwe Schmidt: A Peer-to-Peer Simulator 3 / 28
  4. 4. Introduction Model Simulation Application Summary Peer-to-Peer File-Sharing Gaining Importance Less expensive in comparison to dedicated file servers Exploit bandwidth of users Resilient to flashcrowds BitTorrent Files are separated into chunks Popular (also for legal purposes) Microsoft Avalanche Uses network coding for chunk distribution Uwe Schmidt: A Peer-to-Peer Simulator 4 / 28
  5. 5. Introduction Model Simulation Application Summary Motivation Freeriding Common problem of all P2P systems Large fraction of peers are free-riders BitTorrent tries to restrain it by enforcing a tit-for-tat strategy Primary purpose of the simulator: Research the impact of the amount of free-riders on ... Download times Peer load Uwe Schmidt: A Peer-to-Peer Simulator 5 / 28
  6. 6. Introduction Model Simulation Application Summary Outline Introduction 1 Model 2 Simulation 3 Application 4 Uwe Schmidt: A Peer-to-Peer Simulator 6 / 28
  7. 7. Introduction Model Simulation Application Summary General Similar to BitTorrent (chunk-based file-sharing) Global knowledge of all other peers in the system No incentives to upload are given (such as tit-for-tat) Peers wait random time between downloads Peer Chunk Selection Download Behavior File Multiple Downloads Chunk#1 Chunk#2 ... Chunk#n Peer Selection Queued Requests Peer Lists for Chunks Chunk Selection Peer#13 Peer#11 Peer Selection Peer#6 Peer#2 List List List Peer#5 Peer#40 Peer#77 Peer#8 Peer#19 Uwe Schmidt: A Peer-to-Peer Simulator 7 / 28
  8. 8. Introduction Model Simulation Application Summary General Configuration GUI Uwe Schmidt: A Peer-to-Peer Simulator 8 / 28
  9. 9. Introduction Model Simulation Application Summary Peers Separated into peer groups: Peer Group Number of members Number of free-riders Bandwidth (upstream & downstream) Maximum number of simultaneous uploads & downloads Disconnect probability after successful file download Uwe Schmidt: A Peer-to-Peer Simulator 9 / 28
  10. 10. Introduction Model Simulation Application Summary Peers Configuration GUI Uwe Schmidt: A Peer-to-Peer Simulator 10 / 28
  11. 11. Introduction Model Simulation Application Summary Files Separated into file types: File Type Number of files Number of copies (per file) File size (determines number of chunks) File distribution to peer groups Popularity distribution of files among type Global Chunk Size Applies to all file types Uwe Schmidt: A Peer-to-Peer Simulator 11 / 28
  12. 12. Introduction Model Simulation Application Summary Files Configuration GUI Uwe Schmidt: A Peer-to-Peer Simulator 12 / 28
  13. 13. Introduction Model Simulation Application Summary Requests Mean request period Request distribution to file types Uwe Schmidt: A Peer-to-Peer Simulator 13 / 28
  14. 14. Introduction Model Simulation Application Summary Requests Configuration GUI Uwe Schmidt: A Peer-to-Peer Simulator 14 / 28
  15. 15. Introduction Model Simulation Application Summary Outline Introduction 1 Model 2 Simulation 3 Application 4 Uwe Schmidt: A Peer-to-Peer Simulator 15 / 28
  16. 16. Introduction Model Simulation Application Summary Preliminaries Factories Create peers and files Deploy files to peers File Request Generator Uses request configuration and file popularity settings Creates empirical distributions for file indexes Replays this distributions during the simulation Uwe Schmidt: A Peer-to-Peer Simulator 16 / 28
  17. 17. Introduction Model Simulation Application Summary Discrete Event Simulation Concept Ordered Event List Simulation Executive removes executes Next Event inserted changes state appends data Entities schedule append data New Events Data Collection Uwe Schmidt: A Peer-to-Peer Simulator 17 / 28
  18. 18. Introduction Model Simulation Application Summary Simulation Cycle File Request Generator Peer Download Part Upload Part Download File Incoming Chunk Request Add Chunks to More Uploads Download Complete Download Queue possible? yes no Last Chunk Process Download Queue Upload Chunk Queue Chunk Request no of File? yes More Downloads Maybe Chunk Download started Chunk Request Queued Upload Complete Update Uploads possible? go Ofline yes no Maybe start Select Chunk Update Downloads Process Upload Queue new Request Select Peer Download Chunk Uwe Schmidt: A Peer-to-Peer Simulator 18 / 28
  19. 19. Introduction Model Simulation Application Summary Control Uwe Schmidt: A Peer-to-Peer Simulator 19 / 28
  20. 20. Introduction Model Simulation Application Summary Collected Data Before the Simulation Peer groups File types List of files with chunk mapping List of peers with file mapping During the Simulation Completed chunk transfers Completed file downloads Miscellaneous (e.g. peer goes offline) After the Simulation List of peers with file mapping Uwe Schmidt: A Peer-to-Peer Simulator 20 / 28
  21. 21. Introduction Model Simulation Application Summary Outline Introduction 1 Model 2 Simulation 3 Application 4 Uwe Schmidt: A Peer-to-Peer Simulator 21 / 28
  22. 22. Introduction Model Simulation Application Summary Overview Written in Java SE 5 Used Eclipse 3 58 classes in 8 packages ≈ 8000 lines of code and comments (JavaDoc) Used Libraries Jakarta Commons Math → Random Number Generators Jakarta Commons Configuration → XML Configuration JFreeChart → Charts Uwe Schmidt: A Peer-to-Peer Simulator 22 / 28
  23. 23. Introduction Model Simulation Application Summary Structure User starts starts Graphical User Interface Console Mode controls controls Simulator changes uses executes File Request Generator Factories Next Event uses uses use create create writes controls returns Files Configuration Files Peers to download save load uses use consist of transfer use schedule write removes Config File Chunks Strategies New Events Log Files use inserted Random Number Generators Event List Uwe Schmidt: A Peer-to-Peer Simulator 23 / 28
  24. 24. Introduction Model Simulation Application Summary Used Design Patterns Observer Pattern Simulator → Simulation State Progress Configuration → Changes Singleton Pattern Implemented by frequently used components Single point of access from everywhere No need to pass references on to other components Command Pattern Hashtable that maps an ActionString to a Command Avoid code duplication Uwe Schmidt: A Peer-to-Peer Simulator 24 / 28
  25. 25. Introduction Model Simulation Application Summary Extensions General modular design Selection strategies are easy to change and extend Example (Chunk Selection) Select rarest chunk among 50 randomly selected ones to reflect that peers have no global knowledge in reality Example (Peer Selection) Select peer with most upstream left Select peer with smallest upload queue (if all are busy) Uwe Schmidt: A Peer-to-Peer Simulator 25 / 28
  26. 26. Introduction Model Simulation Application Summary Demo Uwe Schmidt: A Peer-to-Peer Simulator 26 / 28
  27. 27. Introduction Model Simulation Application Summary Summary Easy and flexible way to simulate P2P systems (similar to BitTorrent) Tool to research the impact of free-riders, and other parameters, on a P2P system Modular designed and extendable Uwe Schmidt: A Peer-to-Peer Simulator 27 / 28
  28. 28. Thank you for your attention Questions? Uwe Schmidt: A Peer-to-Peer Simulator 28 / 28

×