Spring Boot build process

Spring Boot build process
1. Basic requirements
1. Use version
In this section, take 1.5.6.RELEASE version as an example to explain Spring Boot. By default, this version needs to be used in Java 7 environment and Spring Framework 4.3.10.REL EASE or above. Since Spring Boot officially recommends the Java 8 environment, the Java version used here is Java 8.
2. Build tools
Currently, Maven (3.2+), Gradle2 (2.9 or later) and Gradle3 are clearly supported for building Spring Boot 1.5.6.RELEASE. The Maven 3.5.0 version is used here.
3. The development tool
Spring Boot can use Spring Tool Suite (STS) or IntelliJ IDEA. Here we will use the Eclipse Neon.3 Release (4.6.3) version with STS plug-in to explain.
Second, build Maven
1. Install Eclipse inheriting STS.
2. Unzip the Maven package.
(1) Unzip the apache-maven-3.5.0 and MavenRepository packages, open the settings.xml file under the MavenRepository package, copy it, as shown below:
Insert picture description here
replace the settings.xml file under apache-maven-3.5.0 \ conf . As shown below:
Insert picture description here
Because the original settings.xml file will be downloaded from the Internet regardless of whether there is a jar package locally, the replacement file has been modified to make it preferentially downloaded from the local.
3. Integrate Maven onto Eclipse
(1) Open Eclipse.
(2) Open Window—> Preferences in the menu bar, search for Mave ------> User Settings, and add the path of the Settings.xml file just replaced in Global Settings. The location of the Local Repository underneath must be the same as the location of the decompressed warehouse. If they are inconsistent, click open file in the figure to open the file and modify it in the file. As shown below:
Insert picture description hereInsert picture description here
Third, build the Spring Boot project
1. Log in to the website https://start.spring.io/ .
Insert picture description here
2. Create a project. Insert picture description here
Insert picture description here
3. Download the created project.
Insert picture description here
4. Open the file, open the pom.xml file, and modify the configuration.
Insert picture description here
Insert picture description here
5. Open Eclipse and import the modified project.
Insert picture description here
6. Run the startup class to start the project.
Insert picture description here
Successfully launched page.
Insert picture description here
7. Write control class.
Insert picture description here
8. Visit in the browser.

Insert picture description here
At this point, the Spring Boot project is completed.
Download address of all information in this article: SpringBoot
has any questions, please leave a message!

Published 8 original articles · Like1 · Visits 383

Guess you like

Origin blog.csdn.net/weixin_42064000/article/details/105040782