VMware 2V0-72.22 - Professional Develop VMware Spring Exam
Page: 1 / 18
Total 90 questions
Question #1 (Topic: Exam A)
If a class is annotated with @Component, what should be done to have Spring automatically detect the annotated class and load it as a bean? (Choose the best answer.)
A. Ensure a valid bean name in the @Component annotation is specified.
B. Ensure a valid @ComponentScan annotation in the Java configuration is specified.
C. Ensure a valid @Scope for the class is specified.
D. Ensure a valid @Bean for the class is specified.
Answer: A
Question #2 (Topic: Exam A)
Which two options will inject the value of the daily.limit system property? (Choose two.)
A. @Value(“#{daily.limit}”)
B. @Value(“$(systemProperties.daily.limit)”)
C. @Value(“$(daily.limit)”)
D. @Value(“#{systemProperties[‘daily.limit’]}”)
E. @Value(“#{systemProperties.daily.limit}”)
Answer: BD
Question #3 (Topic: Exam A)
Which two options are REST principles? (Choose two.)
A. RESTful applications use a stateless architecture.
B. RESTful application use HTTP headers and status codes as a contract with the clients.
C. RESTful applications cannot use caching.
D. RESTful application servers keep track of the client state.
E. RESTful applications favor tight coupling between the clients and the servers.
Answer: AB
Question #4 (Topic: Exam A)
Which option is true about use of mocks in a Spring Boot web slice test? (Choose the best answer.)
A. Mocking a Spring Bean requires annotating it with @MockBean annotation.
B. If a Spring Bean already exists in the web slice test spring context, it cannot be mocked.
C. Mocks cannot be used in a Spring Boot web slice test.
D. Mocking a Spring Bean requires annotating it with @Mock annotation.
Answer: A
Question #5 (Topic: Exam A)
Which two statements are true regarding Spring Security? (Choose two.)
A. Access control can be configured at the method level.
B. A special Java Authentication and Authorization Service (JAAS) policy file needs to be configured.
C. Authentication data can be accessed using a variety of different mechanisms, including databases and LDAP.
D. In the authorization configuration, the usage of permitAll () allows bypassing Spring security completely.
E. It provides a strict implementation of the Java EE Security specification.
Answer: AD