Skip to content
Extraits de code Groupes Projets
README.md 2,91 ko
Newer Older
  • Learn to ignore specific revisions
  • # Implementation of TRTP Protocol - LINFO1341 Project
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    ## 1. Introduction 
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    For the course **LINFO1341 : Conputer Network**, given to 3rd year computer science students at UCLouvain, we had to implement a transport protocol. The protocol is entitled **Truncated Relieable Transport Protocol (TRTP)** on top of a Ipv6 Network layer. The protocol also implement the **Forward Erasure Correction (FEC)** to recover corrupted packets. The full description of the protocol is to be found in the `statement.pdf`.
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    ## 2. Execution
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    In order to execute the code, one must first execute the Makefile:
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    make
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    For debugging please run 
    ```
    make debug
    ```
    Then use the specified arguments explained in the `statement.pdf`.
    
    ## 3. Folder Organization 
    
    ```
    | headers/
    | linksimulator/
    | src/
    | test_files/
    | tests/
    | unwanted_logs/
    ```
    
    ### 3. 1. `linksimulator/`
    This folder contains a [git repository](https://github.com/cnp3/Linksimulator). We use the linksimulaor to simulate a network with certain configurations like packets loss, delays, etc. Full description in the `linksimulator/README.md`. We did not write any of the code in the folder. 
    
    ### 3. 2. `test_files/`
    
    This folder contains testing files that we will be sendig between the `receiver` and the `sender`. Any file added to this folder will automatically be used in tests suites. 
    
    
    ## 4. Testing
    
    For the testing we have a specific directory that contains our shell script tests. In order to execute our tests we advise to run the following Makefile command 
    ```
    make tests -s
    ```
    The silent argument `-s` is to silence any Makefile output and only leave the messages of the tests. In order to test the transfer of a file, you have to add a file in the `test_files`. The suite cases will automatically load the fle and transfer using our protocol.
    
    We have two types of tests suites. *Simple* and *Advanced* test suites. 
    
    ### 4. 1. *Simple* Test Suites
    
    Simple tests don't use `linksimulator`, however they use `Valgrind` to check memory usage in both the sender and the receiver. After executing the `make [debug]`. One can run a simple test with the following command :
    
    ```
    ./tests/simple_test.sh <path_to_file>
    ```
    
    The output for each file sent using the simple test is to be found in the `unwanted_logs/`. They respect the following format :
    
    | File in `unwanted_logs/` | Contains |
    | :-- | :-- |
    | `<file_basename>`_received_file.`<file_extension>` | This is the file received by the `receiver`.|
    | `<file_basename>`_receiver.log | Contains the valgrind log of the `receiver`. |
    | `<file_basename>`_sender.log | Contains the valgrind log of the `sender`. |
    | receiver.log | Contains the output on the stderr of the `receiver`. |
    | sender.log | Contains the output on the stderr of the `sender`. |
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    The stdout prints *Le transfert est réussi!*, upon success else it prints the comparison between the sent file and the received file. 
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    ### 4. 2. *Advanced* Test Suites
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    TBA ...
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    ## 5. System Architecture
    
    Vany Ingenzi's avatar
    Vany Ingenzi a validé
    TBA ...