A. It causes Spring Boot to enable auto-configuration by default.
This is true because the @SpringBootApplication annotation includes the @EnableAutoConfiguration annotation, which enables Spring Boot’s auto-configuration mechanism1. Auto-configuration attempts to automatically configure your Spring application based on the jar dependencies that you have added2.
B. Component scanning will start from the package of the class.
This is true because the @SpringBootApplication annotation includes the @ComponentScan annotation, which enables component scanning on the package where the application is located1. Component scanning allows Spring to automatically detect and register beans annotated with @Component, @Controller, @Service, @Repository, etc3.
Contribute your Thoughts:
Chosen Answer:
This is a voting comment (?). You can switch to a simple comment. It is better to Upvote an existing comment if you don't have anything to add.
Submit