VMware 2V0-72.22 Professional Develop VMware Spring Online Training
VMware 2V0-72.22 Online Training
The questions for 2V0-72.22 were last updated at Nov 22,2024.
- Exam Code: 2V0-72.22
- Exam Name: Professional Develop VMware Spring
- Certification Provider: VMware
- Latest update: Nov 22,2024
Which two statements are true regarding Spring Boot Testing? (Choose two.)
- A . @TestApplicationContext is used to define additional beans or customizations for a test.
- B . Test methods in a @SpringBootTest class are transactional by default.
- C . @SpringBootTest is typically used for integration testing.
- D . Test methods annotated with @SpringBootTest will recreate the ApplicationContext.
- E . @SpringBootTest without any configuration classes expects there is only one class annotated with@SpringBootConfiguration in the application.
Which two use cases can be addressed by the method level security annotation @PreAuthorize? (Choose two.)
- A . Allow access to a method based on user identity.
- B . Allow access to a method based on the returned object.
- C . Allow access to a method based on HTTP method.
- D . Allow access to a method based on request URL.
- E . Allow access to a method based on roles.
Which two statements are true regarding a Spring Boot-based Spring MVC application? (Choose two.)
- A . The default embedded servlet container can be replaced with Undertow.
- B . Jetty is the default servlet container.
- C . Spring Boot starts up an embedded servlet container by default.
- D . The default port of the embedded servlet container is 8088.
- E . Spring MVC starts up an in-memory database by default.
What are the two reasons Spring be used to build a Java application? (Choose two.)
- A . Spring automates a Java application build.
- B . Spring provides a Dependency Injection container.
- C . Spring automates deployment of Java applications to all of the major cloud providers.
- D . Spring provides comprehensive Java IDE support.
- E . Spring provides abstractions over infrastructure such as persistence and messaging.
Which two statements are correct regarding the @EnableAutoConfiguration annotation? (Choose two.)
- A . It is a meta-annotation on the @SpringBootApplication composed annotation.
- B . It enables auto-configuration of the ApplicationContext by attempting to guess necessary beans.
- C . It is meta-annotation on the @SpringBootConfiguration composed annotation.
- D . It has the same effect regardless of the package of the class that is annotated with it.
- E . It ensures auto-configuration is applied before user-defined beans have been registered.
Which two are required to use transactions in Spring? (Choose two.)
- A . Add @EnableTransactionManagement to a Java configuration class.
- B . Annotate a class, an interface, or individual methods requiring a transaction with the @Transactional annotation.
- C . A class must be annotated with @Service and @Transaction.
- D . A class requiring a transaction must implement the TransactionInterceptor interface.
- E . Write a Spring AOP advice to implement transactional behavior.
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.)
- A . A HelloService bean will be created from the helloService() method even if the HelloService.class is not in the classpath.
- B . A HelloService bean will be created from the helloService() method only when there is no other HelloService bean in the ApplicationContext.
- C . This auto-configuration class is used only when the HelloService.class is not on the classpath.
- D . This auto-configuration class is used only when the HelloService.class is on the classpath.
- E . A HelloService bean will be created from the helloService() method and will replace existing a HelloService bean in the ApplicationContext.
Which two statements are true regarding bean creation? (Choose two.)
- A . A Spring bean can be explicitly created by annotating methods or fields by @Autowired.
- B . A Spring bean can be implicitly created by annotating the class with @Component and using the component-scanner to scan its package.
- C . A Spring bean can be implicitly created by annotating the class with @Bean and using the component- scanner to scan its package.
- D . A Spring bean can be explicitly created using @Bean annotated methods within a Spring configuration class.
- E . A Spring bean can be explicitly created by annotating the class with @Autowired.
Which statement defines a pointcut? (Choose the best answer.)
- A . A point in the execution of a program such as a method call or field assignment.
- B . An expression that selects one or more join points.
- C . A module that encapsulated advices.
- D . Code to be executed at each selected join point.
Which two statements are correct regarding the Health Indicator status? (Choose two.)
- A . The last status in a sorted list of HealthIndicators is used to derive the final system health.
- B . The status with the least severity is used as the top-level status.
- C . Custom status values can be created.
- D . The built-in status values are DOWN, OUT_OF_SERVICE, UNKNOWN, and UP in decreasing order of severity.
- E . The severity order cannot be changed due to security reasons.