Skip to content

lokesh-wagh/p2p-file-sharing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

P2P File Sharing Guide

How To Use

Basic Program Compilation

  1. Navigate to the src folder and run the following command:
    javac -cp . ./Main/Main.java ./discovery/.java ./discovery/messages/.java ./p2p/.java ./testing/.java
  2. Start the central server:
    java -cp . Main.Main central <!CentralServerIP!> <!CentralServerPort!>
  3. Start a peer:
    java -cp . Main.Main peer <!PeerIP!> <!PeerPort!> <!CentralServerIP!> <!CentralServerPort!>

How To Upload a File

  1. Run the peer command as shown above.
  2. Use the following command to upload a file:
    upload <!FILEPATHINOS!>

How To Download a File

  1. Run the peer command as shown above.
  2. Use the following command to download a file:
    download

How to Test

  1. In the test directory, add a file containing the paths of all the files to be tested.
  2. Run the following command to start testing:
    java -cp . Main.Main testing <!test Name!>

    Currently, the test will use a three-node setup to perform the testing.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages