Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

This project implements a Java-based client-server file transfer system. The client lists or uploads text files, while the server handles multiple clients concurrently, logging all requests and managing file uploads with error handling for duplicates.

NotificationsYou must be signed in to change notification settings

rubayeaAlketbi/Simple-File-Transfer-Network-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Overview

This project implements a simple file transfer system using client-server architecture in Java. The system allows clients to request a list of text files on the server and upload new files. The server handles multiple clients using a multi-threaded design.

Features

  • Client:

    • list: Lists all files on the server.
    • put fname: Uploads a file (fname) to the server. Returns an error if the file already exists.
  • Server:

    • Manages up to 20 concurrent client connections using a thread pool.
    • Stores uploaded files in theserverFiles directory.
    • Logs all valid client requests inlog.txt.

Directory Structure

cwk/ ├── client/ │ ├── Client.java │ └── lipsum2.txt (example file to upload) ├── server/ │ ├── Server.java │ └── serverFiles/ │ └── lipsum1.txt (example file on the server)

How to Run

Server Setup

  1. Navigate to theserver directory and compile the Java files:
    cd cwk/serverjavac Server.java
  2. Start the server:
    java Server

Client Setup

  1. In another terminal, navigate to the client directory and compile the Java files:

    cd cwk/clientjavac Client.java
  2. Execute the client with the appropriate command:

    To list all files on the server:

      java Client list

    To upload a file to the server:

       java Client put lipsum2.txt

About

This project implements a Java-based client-server file transfer system. The client lists or uploads text files, while the server handles multiple clients concurrently, logging all requests and managing file uploads with error handling for duplicates.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp