Coder Social home page Coder Social logo

springrestfulapi's Introduction

Spring framework RESTful Web API To do Lists

Demonstrates a simple RESTful web service using Spring framework and Java. This web service provides an in-memory order management service, with the capability to GET, PATCH, and POST.

Starting the Service

To start this web service, cd into RESTfulWebAPI, and execute the following command

mvn spring-boot:run

Once the web service is started, it can be reached at

http://localhost:8080/RESTfulWebAPI/todoList/

There is no fake data, user needs to post data first, it should be JSON object with the fields title, description and dueDate, which should be like this,

{
    "title": "1",
    "description": "To do 1",
    "dueDate": "19-Feb-2018 08:03:01"    
}

Test

Under PostmanTests folder, there are three unit tests file for GET, POST and PATCH, one integration test file, these can be used in Postman. All cases passed. Because this service doesn't implement DELETE, it requires to restart the service when each test is finished.

Incompelete implementation

The requirements for the POST is

Done when an unsuccessful POST due to any reason returns an HTTP 400 status

The service will only returns HTTP 400 status when there is already an exist to do list, it may have some other corner cases for this implement.

springrestfulapi's People

Contributors

xz9876 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.