Professional Documents
Culture Documents
| + project
| | - MyApp.java
FEATURES | | |
| | + player
| | | - PlayerService.java
Default logger (@see spring-jcl)
FailureAnalyzers : friendly failure report
Application Events on Listeners Configuration
Choose the right ApplicationContext
Accessing application arguments Properties files in folder src/main/resources/ are loaded
Control application exit code automatically
YAML : **/application*.yml or
QUICKSTART **/application*.yaml
Properties : **/application*.properties
<parent>
<groupId>org.springframework.boot</groupId>
Auto-configuration
<artifactId>spring-boot-starter-
parent</artifactId>
Enabled by @SpringBootApplication or
<version>2.1.0.RELEASE</version>
@EnableAutoConfiguration
</parent>
Spring Boot scans all libs on the classpath and auto-
<dependencies>
<groupId>org.springframework.boot</groupId>
Display Spring Boot Autoconfigure report
<artifactId>spring-boot-starter</artifactId>
</dependency>
java -jar myapp.jar --debug
</dependencies>
Disabling an auto-configuration class with Java conf
@SpringBootApplication
SpringApplication.run(MyApp.class, args);
} spring.autoconfigure.exclude= \
org.springframework.boot.autoconfigure.XXXX
<plugins>
<plugin>
Name Function
<groupId>org.springframework.boot</groupId>
Web applications using Spring MVC
<artifactId>spring-boot-maven- web
plugin</artifactId>
(Tomcat embedded)
</plugin>
Spring test using JUnit, Hamcrest
</plugins>
test
</build> and Mockito
Secured services with Spring
security
Gradle Security
WebFlux applications using Spring
plugins {
webflux
id 'org.springframework.boot' version Framework’s Reactive Web
'2.1.0.RELEASE'
WebSocket applications using
} websocket
Spring Framework’s WebSocket
Actuator Configured resources to use Spring
data-jdbc
Data JDBC
Production ready features threw HTTP or JMX data- Configured resources to use Spring
<dependency>
Maven GO DEEPER