Spring Boot is the framework under Spring projects umbrella to bootstrap Spring applications. It provides few ways in which you can create a Spring application e.g GUI, CLI based.

Using Maven

This is bit old fashioned but you will get to know what is really going under the hood. First create a normal maven project in Eclipse. In pom.xml add the spring-boot related dependencies you want to use in the project.

SPRING INITIALIZR

Go to the site start.spring.io This is the official Spring site for bootstraping Spring applications. You can select the various options whether you want to use Maven or Gradle and the Spring Boot version.

Fill the Group, Artifact, Name, Description for your project.

Add the required dependencies by adding the appropriate keywords e.g. Web, Security etc.

If you want to fine tune your dependencies, switch to full version. There are many categories you can choose dependencies from e.g. Core, Web, I/O, SQL, NoSQL etc.

Upon click of Generate Project, project will be downloaded in zip format. Import this to your favorite IDE and start writing your business logic. 🙂

Spring Boot CLI

If you are more of command-line fan, Spring also provides CLI utility for creating Spring applications using Boot.

You can download the latest version of utility from here. Extract the zip file in your file system and include that path in Windows PATH Environment Variable, so that you can run spring commands from anywhere.

Spring Boot CLI provides spring command to execute Spring Boot Groovy scripts.

Syntax

spring run <SpringBoot-Groovy-Script-Name>

Let me know in comments which is your favorite way to create Spring applications. 🙂