Monday, October 10, 2016

Spring Boot

@SpringBootApplication annotation is equivalent to using @Configuration @EnableAutoConfiguration @ComponentScan”

@SpringBootApplication = @Configuration + @EnableAutoConfiguration + @ComponentScan
  • @Configuration tags the class as a source of bean definitions for the application context.
  • @EnableAutoConfiguration tells Spring Boot to start adding beans based on class path settings, other beans, and various property settings.
  • @ComponentScan tells Spring to look for other components, configurations, and services in the base package.

No comments:

Post a Comment