2V0-72.22PSE · Question #10
Refer to the exhibit. Which two statements are correct regarding the HelloAutoConfig auto- configuration class when it is specified in the META-INF/spring.factories file? (Choose two.)
The correct answer is B. A HelloService bean will be created from the helloService() method only when there is no other D. This auto-configuration class is used only when the HelloService.class is on the classpath. https://docs.spring.io/spring-boot/docs/1.2.5.RELEASE/reference/html/boot-features-developing- auto-configuration.html#boot-features-class-conditions https://docs.spring.io/spring-boot/docs/1.2.5.RELEASE/reference/html/boot-features-developing…
Question
Refer to the exhibit. Which two statements are correct regarding the HelloAutoConfig auto- configuration class when it is specified in the META-INF/spring.factories file? (Choose two.)
Exhibit
Options
- AA HelloService bean will be created from the helloService() method even if the
- BA HelloService bean will be created from the helloService() method only when there is no other
- CThis auto-configuration class is used only when the HelloService.class is not on the classpath.
- DThis auto-configuration class is used only when the HelloService.class is on the classpath.
- EA HelloService bean will be created from the helloService() method and will replace existing a
How the community answered
(57 responses)- A5% (3)
- B81% (46)
- C11% (6)
- E4% (2)
Explanation
https://docs.spring.io/spring-boot/docs/1.2.5.RELEASE/reference/html/boot-features-developing- auto-configuration.html#boot-features-class-conditions https://docs.spring.io/spring-boot/docs/1.2.5.RELEASE/reference/html/boot-features-developing- auto-configuration.html#boot-features-bean-conditions
Topics
Community Discussion
No community discussion yet for this question.
