The Spring Boot configuration
In this section, the focus will be on the configuration aspects of Spring Boot. The chapter2.bootrest
project, already developed, will be modified in this section to showcase configuration capabilities. Copy and paste chapter2.bootrest
and rename the project as chapter2.boot-advanced
.
Understanding the Spring Boot autoconfiguration
Spring Boot uses convention over configuration by scanning the dependent libraries available in the class path. For each spring-boot-starter-*
dependency in the POM file, Spring Boot executes a default AutoConfiguration
class. AutoConfiguration
classes use the *AutoConfiguration
lexical pattern, where *
represents the library. For example, the autoconfiguration of JPA repositories is done ...
Get Spring Microservices now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.