Create Spring Boot project in Spring-tool-Suite (STS)
There are two ways to create Spring Boot project either by using https://start.spring.io or IDE. So, Let's begin.
- Create Spring Boot project using spring tool suite or you can use https://start.spring.io:
|
Create New Spring Boot project using Spring Tool Suite |
- Provide necessary details in https://start.spring.io or IDE such as name, type, Packaging, Java Version, Language, etc. For example:
|
Details for creating project using STS |
|
Add Dependencies in start.spring.io and generate project |
- Select Spring Boot Version, and select the dependencies required for your project. I am taking the following dependency in my project:
- Rest Repository - Exposing Spring Data repositories over REST via Spring Data REST.
- Spring Data JPA - Persist data in SQL stores with Java Persistence API using Spring Data and Hibernate.
- MySQL Driver - MySQL JDBC driver.
- Spring Boot DevTools - Provides fast application restarts, LiveReload, and configurations for enhanced development experience.
- Spring Web Starter - Build web, including RESTful, applications using Spring MVC.
- Click on finish in IDE. If you are creating project start.spring.io then, generate the project as zip, extract it and import in IDE.
- After successful create/import project, structure will look like:
|
Structure after project creation |
Enjoy learning. :)
No comments:
Post a Comment