Giter VIP home page Giter VIP logo

bittorrentonudp's Introduction

#################################################################################
# README                                                                        #
#                                                                               #
# Description: This file serves as a README and documentation for 15441 Project2#
#                                                                               #
# Authors: Yao Zhou <[email protected]>,                                       #
#          Ming Fang <[email protected]>                                         #
#                                                                               #
#################################################################################




[TOC-1] Table of Contents
--------------------------------------------------------------------------------

        [TOC-1] Table of Contents
        [DES-2] Description of Files
        [DES-3] Description of Design for checkpoint1
        [DES-4] Description of Design for checkpoint2



[DES-2] Description of Files
--------------------------------------------------------------------------------

Here is a listing of all files associated with Recitation 1 and what their'
purpose is:

     .../readme.txt              - Current document 
     .../vulnerabilities.txt     - File contains the potential vulnerabilities of this project
     .../test.txt                - File contains test case
     .../bt_parse.[c.h]          - Parse command line and config file
     .../chunk.[c.h]             - Process chunks
     .../client.c                - A simple client which is used to test UDP connection
     .../debug-text.h            - A file contains debug type 
     .../debug.[c.h]             - Helpful utilities for debugging output
     .../debugparse.pl           - Parse a debug.h file to create a debug-text.h file
     .../hupsim.pl               - This file emulates a network topology using topo.map
     .../input_buffer.[c|h]      - Handle user input
     .../job.[c|h]               - Process current job(downloading|uploading)
     .../timer.[c|h]             - Helper functions for timing
     .../conn.[c|h]              - Functions and structs that maintain connections
     .../make_chunks.c           - Source code for make-chunks executable fils
     .../nodes.map               - A map contains all nodes in the network
     .../peer.c                  - Process peers(main function)
     .../queue.[c|h]             - A generic queue  
     .../server.c                - A simple s   server which is used to test UDP connection
     .../sha.c.[c|h]             - SHA-1 hash generator
     .../spiffy.[c|h]            - A simple network simulator
     .../test_input_buffer.c     - A simple test for user input
     .../topo.map                - A map file contains the network topology
     .../Makefile                - Contains rules for make




[DES-3] Description of Design for checkpoint1
--------------------------------------------------------------------------------
This project implements a peer to peer download application. By checkpoint 1, we have 
implemented the following functionalities:
1 Peer initialized with the knowledge of self information including identity, hasChunks, 
  and other reachable peers.
2 Peer is able to receive GET command from the command line.
3 Peer is able to parse the GET command and send WHOHAS packet to all reachable peers to
  discover available peers which has the desired file.
4 Peer is able to generate IHAVE response to received WHOHAS packet and send back. Peer
  does not send back IHAVE response if it does not have any requested file

[DES-4] Description of Design for checkpoint2
--------------------------------------------------------------------------------
1 When a peer receive IHAVE response, it is able to generate corresponding GET requests
  and send then one after one.
2 When a peer receive GET request, it is able to generate corresponding DATA packets and
  send them under the constraint of congestion control.
3 A sending peer is able to maintain a congestion window, which has an initial value of 8
  and a ssthresh of 64. The window size is changing at the time of receiving ACK
  packet and the changing value depends on the current state of sending peer, which is either
  slow start or congestion avoidance.
4 When a peer receive a DATA packet, it is able to, according to the sequence number of DATA
  packet, generate corresponding ACK packet and decide whether to store the data or drop it.
5 A peer is able to maintain a upload pool and a download pool with given number of connections.
6 when there’s a timeout occurred(10 seconds no response), the downloading peer is able to find 
  other available peers to re-start download.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.