Skip to content

vinodkashyap/SpringRestMongo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 

Repository files navigation

SpringRestMongo

Sample Java project with Spring, REST and MongoDB based on Maven. It uses default database of MongoDB i.e. test. It will automatically create a collection (table in RDBMS) with name schools.

Technologies Used

  • Java 8
  • Spring 4
  • Maven 3
  • MongoDB

Requirements

How to Run

It is a REST based project and there is no UI for it.
So you need to test in some REST client. 
Simply deploy application on your local server and access using REST client

REST URL hits

  • Fetch all schools: GET http://localhost:8080/spring-mongo
  • Insert dummy data: POST http://localhost:8080/spring-mongo
  • Update school: PUT http://localhost:8080/spring-mongo/{school_id}. This will only update schools name to British International
  • Fetch a school by its id: GET http://localhost:8080/spring-mongo/{school_id}
  • Delete a school by its id: DELETE http://localhost:8080/spring-mongo/{school_id}
  • Delete all schools: DELETE http://localhost:8080/spring-mongo

About

Demo Java project with Spring, REST and MongoDB

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages