Coder Social home page Coder Social logo

file-server's Introduction

File Server

Author: Mohammed Ibrahim Ahmed | github.com/moh-i-ahmed

Description: My implementation of a simple RESTful file server built using Java, Spring Boot & Spring Web. The server provides the following endpoints:

Endpoint Description
http://localhost:8080/files/ Retrieves list of all uploaded files with their name and download link
http://localhost:8080/files/open_me.txt Downloads the open_me.txt file present in the project
http://localhost:8080/files/upload Uploads a file to the server

Pre-requisites & setup

This application has been developed and tested only with the following, please ensure you have the Java and Gradle 8.5 versions installed.

Run instructions

Running the application:

  1. Open a terminal and navigate to the project's root directory.

    • cd <path_to_folder_containing_project\File-Server
  2. Start the file server using the gradle wrapper command:

    • .\gradlew bootRun
  3. In your browser or using a program such as Postman, access the endpoints described above.

Running the unit tests:

  1. Open a terminal and navigate to the project's root directory.

    • cd <path_to_folder_containing_project\File-Server
  2. Run the tests using the gradle wrapper command:

    • .\gradlew clean test --info
  3. The results will be displayed in the terminal and will also be stored in the folder:

    • File-Server\build\test-results folder

Project structure

File Server: The file server code is located in the folder File-Server\src\main\java\fileServer\FileServer

Unit tests: The unit tests are located in File-Server\src\test\java\fileServer\FileServer\FileServerEndpointTests.java

file-server's People

Contributors

moh-i-ahmed avatar

Watchers

 avatar

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.