Spring Boot
is a new framework provided by the pivotal team, designed to simplify Spring
the initial construction and development of new applications. The framework uses a specific approach to configuration, which eliminates the need for developers to define boilerplate configurations. In this way, boot is committed to becoming a leader in the burgeoning field of rapid application development rapid application development
.
Features of Spring Boot
1. Create a standalone Spring
application
2. Direct embedding Tomcat
, Jetty
or Undertow
, no need to deploy WAR
files
3. Provide the recommended base POM
file to simplify the Apache Maven
configuration
4. Automatically configure the framework based on project dependencies as much as possible Spring
5. Provide production-ready features such as indicators, health checks and external configurations
6. Absolutely no code generation and XML
no configuration required
The advantages of Spring boot
spring boot
Can support developers to quickly develop a restful
style of micro-service architecture;
spring boot
Automation is really convenient, and the micro-service is suitable, single jar package deployment and management are very convenient. As long as the system architecture design is reasonable, large-scale projects can be used, coupled with nginx
load balancing, easy to achieve horizontal expansion;
spring boot
To solve the problem, thin provisioning is on the one hand, and on the other hand how to easily spring
integrate the ecosystem and other toolchain (for example, Redis
email
elasticsearch
).
Spring Boot Runtime Environment
Spring Boot most recent (2017-08-18) version Spring Boot 1.5.6
of the operating environment, Spring officially recommends usingJDK1.8
Name |
Servlet Version |
Java Version |
Tomcat 8 |
3.1 |
Java 7+ |
Tomcat 7 |
3.0 |
Java 6+ |
Jetty 9 |
3.1 |
Java 7+ |
Jetty 8 |
3.0 |
Java 6+ |
Undertow 1.1 |
3.1 |
Java 7+ |
Spring Boot
Making it easy to develop an independent, product-level spring-based application, you just need to " just run
." Provides out- Spring
of-the-box settings for platforms and third-party libraries, so you can start in a methodical manner. Most Spring Boot
applications require very little Spring
configuration.
Use Spring Boot
to create Java apps, use Spring
start-up or adopt traditional war
deployment methods. Spring Boot
provides a Spring
command-line tool to run the script.
Spring Boot recommended base pom file
name |
Description |
Spring-boot-starter |
Core POM, which includes automatic configuration support, a log library, and support for YAML configuration files. |
Spring-boot-starter-amqp |
Support AMQP via Spring-rabbit. |
Spring-boot-starter-aop |
Includes SPRING-AOP and AspectJ to support facet-oriented programming (AOP). |
Spring-boot-starter-batch |
Supports Spring Batch, including HSQLDB. |
Spring-boot-starter-data-jpa |
Includes SPRING-DATA-JPA, Spring-orm, and Hibernate to support JPA. |
Spring-boot-starter-data-mongodb |
Contains spring-data-mongodb to support MongoDB. |
Spring-boot-starter-data-rest |
The Spring Data Warehouse is exposed in restful mode through SPRING-DATA-REST-WEBMVC support. |
Spring-boot-starter-jdbc |
Supports access to the database using JDBC. |
Spring-boot-starter-security |
Contains spring-security. |
Spring-boot-starter-test |
Contains the dependencies required for commonly used tests, such as JUnit, Hamcrest, Mockito, and Spring-test. |
Spring-boot-starter-velocity |
Using Velocity as the template engine is supported. |
Spring-boot-starter-web |
Supports WEB application development, including Tomcat and SPRING-MVC. |
Spring-boot-starter-websocket |
Support for developing WebSocket apps with Tomcat. |
Spring-boot-starter-ws |
Supports Spring Web Services. |
Spring-boot-starter-actuator |
Add features for your production environment, such as performance metrics and monitoring. |
Spring-boot-starter-remote-shell |
Add remote SSH Support. |
Spring-boot-starter-jetty |
Use Jetty instead of the default Tomcat as the application server. |
spring-boot-starter-log4j |
Added support for log4j. |
Spring-boot-starter-logging |
Use the Spring Boot default log frame Logback. |
Spring-boot-starter-tomcat |
Use Spring Boot default Tomcat as the application server. |
Spring Boot series (i) Spring boot introduction and base pom file