Show List

Quiz - Spring Boot - 2

65%

Public Average Score
Select the right answer for below questions:

What is the purpose of the @Autowired annotation in Spring Boot?
To define a bean in the Spring configuration file.
To manage transactions in the application.
To automatically wire a bean to another bean.
To define a security configuration for the application.
To automatically wire a bean to another bean.

What is the purpose of the @Primary annotation in Spring Boot?
To define a bean in the Spring configuration file.
To manage transactions in the application.
To define a primary bean among multiple beans of the same type.
To define a security configuration for the application.
To define a primary bean among multiple beans of the same type.

What is the purpose of the @Qualifier annotation in Spring Boot?
To define a bean in the Spring configuration file.
To manage transactions in the application.
To specify a bean by its name for wiring.
To define a security configuration for the application.
To specify a bean by its name for wiring.

What is the purpose of the @ConfigurationProperties annotation in Spring Boot?
To define a bean in the Spring configuration file.
To manage transactions in the application.
To bind properties from external sources to a class.
To define a security configuration for the application.
To bind properties from external sources to a class.

What is the purpose of the @EnableAutoConfiguration annotation in Spring Boot?
To define a bean in the Spring configuration file.
To manage transactions in the application.
To define a security configuration for the application.
To enable auto-configuration for the application.
To enable auto-configuration for the application.

What is the purpose of the @SpringBootTest annotation in Spring Boot?
To test the Spring Boot application.
To define a bean in the Spring configuration file.
To manage transactions in the application.
To define a security configuration for the application.
To test the Spring Boot application.

What is the purpose of the @TestPropertySource annotation in Spring Boot?
To specify properties for testing the application.
To define a bean in the Spring configuration file.
To manage transactions in the application.
To define a security configuration for the application.
To specify properties for testing the application.

What is the purpose of the @MockBean annotation in Spring Boot?
To define a bean in the Spring configuration file.
To manage transactions in the application.
To create a mock bean for testing.
To define a security configuration for the application.
To create a mock bean for testing.

What is the purpose of the @DataJpaTest annotation in Spring Boot?
To test JPA repositories in the application.
To define a bean in the Spring configuration file.
To manage transactions in the application.
To define a security configuration for the application.
To test JPA repositories in the application.

What is the purpose of the @RestController annotation in Spring Boot?
To define a bean in the Spring configuration file.
To define a RESTful web service controller.
To manage transactions in the application.
To define a security configuration for the application.
To define a RESTful web service controller.

Submit
Retry
{"qz1-283939":"To automatically wire a bean to another bean.","qz1-283940":"To define a primary bean among multiple beans of the same type.","qz1-283941":"To specify a bean by its name for wiring.","qz1-283942":"To bind properties from external sources to a class.","qz1-283943":"To enable auto-configuration for the application.","qz1-283944":"To test the Spring Boot application.","qz1-283945":"To specify properties for testing the application.","qz1-283946":"To create a mock bean for testing.","qz1-283947":"To test JPA repositories in the application.","qz1-283948":"To define a RESTful web service controller."}

    Leave a Comment


  • captcha text