Free VMware 2V0-72.22 Practice Test Questions 2026

Total 79 Questions |

Last Updated On : 7-Apr-2026


Professional Develop VMware Spring

Which two annotations indicate that the transaction for a transactional test method should be committed after the test method has completed? (Choose two.)



A. @SqlMergeMode(false)


B. @Rollback(false)


C. @Commit


D. @Sql(alwaysCommit=true)


E. @Transactional(commit=true)





B.
  @Rollback(false)

C.
  @Commit

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.





B.
  A HelloService bean will be created from the helloService() method only when there is no other HelloService bean in the ApplicationContext.

D.
  This auto-configuration class is used only when the HelloService.class is on the classpath.

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.





A.
  The default embedded servlet container can be replaced with Undertow.

C.
  Spring Boot starts up an embedded servlet container by default.

Spring puts each bean instance in a scope. What is the default scope? (Choose the best answer.)



A. prototype


B. singleton


C. request


D. session





B.
  singleton

Which statement about @TestPropertySource annotation is true? (Choose the best answer.)



A. Java system properties have higher precedence than the properties loaded from @TestPropertySource.


B. Properties defined @PropertySource are not loaded if @TestPropertySource is used.


C. @TestPropertySource annotation loads a properties file relative to the root of the project by default.


D. Inlined properties defined in @TestPropertySource can be used to override properties defined in property files.





D.
  Inlined properties defined in @TestPropertySource can be used to override properties defined in property files.

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}”)





C.
  @Value(“$(daily.limit)”)

D.
  @Value(“#{systemProperties[‘daily.limit’]}”)

Refer to the exhibit.

How can a Spring Bean be created from this LegacySingleton class?



A. Call LegacySingleton.getInstance() from within a @Bean method and return the instance.


B. Return an instance of LegacySingleton using the new keyword from a @Bean method.


C. It is not possible without modifying the LegacySingleton class, the constructor must be public.


D. Modify the LegacySingleton class by adding the @Autowired annotation to the instance variable.





A.
  Call LegacySingleton.getInstance() from within a @Bean method and return the instance.

Refer to the exhibit.

Which option is a valid way to retrieve the account id? (Choose the best answer.)



A. Add @PathVariable(“id”) String accountId argument to the update() handler method.


B. Add @PathVariable long accountId argument to the update() handler method.


C. Add @RequestParam long accountId argument to the update() handler method.


D. Add @RequestParam(“id”) String accountId argument to the update() handler method.





B.
  Add @PathVariable long accountId argument to the update() handler method.

Page 2 out of 10 Pages
Next
123
2V0-72.22 Practice Test Home