Spring Sale Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: pass65

2V0-72.22 Professional Develop VMware Spring Questions and Answers

Questions 4

Which two options will inject the value of the daily.limit system property? (Choose two.)

Options:

A.

@Value(“#{daily.limit}”)

B.

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

C.

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

D.

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

E.

@Value(“#{systemProperties.daily.limit}”)

Buy Now
Questions 5

Refer to the exhibit.

2V0-72.22 Question 5

What statement is true about @DirtiesContext?

Options:

A.

It will close the existing cached ApplicationContext and recreate a new one before the test method.

B.

It will close the existing cached ApplicationContext and recreate a new one after the test method.

C.

It will keep the existing cached ApplicationContext, all changes to Spring managed beans will be reverted after the test.

D.

It will recreate only the Spring managed beans that are modified inside the test method.

Buy Now
Questions 6

What ' s the password storage format when using the DelegatingPasswordEncoder?

Options:

A.

encodedPassword{id}, where {id} is an identifier used to look up which PasswordEncoder should be used.

B.

{id}encodedPassword, where {id} is an identifier used to look up which PasswordEncoder should be used.

C.

{timestamp}encodedPassword, where {timestamp} is the time when the password was encoded.

D.

{id}{salt}encodedPassword, where {id} is an identifier used to look up which PasswordEncoder should be used and {salt} a randomly generated salt.

Buy Now
Questions 7

Which two use cases can be addressed by the method level security annotation @PreAuthorize? (Choose two.)

Options:

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.

Buy Now
Questions 8

Which two statements are correct regarding the Actuator info endpoint? (Choose two.)

Options:

A.

It provides configuration options through which only an authenticated user can display application information.

B.

It is not enabled by default.

C.

It can be used to display arbitrary application information.

D.

It can be used to change a property value on a running application.

E.

Typically it is used to display build or source control information.

Buy Now
Questions 9

Which two statements describe Spring JdbcTemplate? (Choose two.)

Options:

A.

All JdbcTemplate methods throw SQLException which you are required to handle.

B.

The JdbcTemplate provides the ability to work with result sets.

C.

The JdbcTemplate can only perform update but not insert to the database.

D.

The JdbcTemplate provides methods for query execution.

E.

The JdbcTemplate generates SQL statements.

Buy Now
Questions 10

Which two are required to use transactions in Spring? (Choose two.)

Options:

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.

Buy Now
Questions 11

Which two mechanisms of autowiring a dependency when multiple beans match the dependency ' s type are correct? (Choose two.)

Options:

A.

Use of @Qualifier annotation on the class and @Autowired annotation either on a field or setter methods.

B.

Use of @Qualifier and @Autowired annotations together with setter methods.

C.

Use of @Qualifier annotation only with setter methods (@Autowired is optional for setters).

D.

Use of @Qualifier and @Autowired annotations together on a field.

E.

Use of @Qualifier annotation only on a field (@Autowired is optional for fields).

Buy Now
Questions 12

Which two statements are true about @Controller annotated classes? (Choose two.)

Options:

A.

The @Controller annotated classes can only render views.

B.

The classes are eligible for handling requests in Spring MVC.

C.

The classes must be annotated together with @EnableMvcMappings to be discovered via component scanning.

D.

@Controller is interchangeable with @RestController with no extra code changes for the methods inside the class.

E.

The @Controller annotation is a stereotype annotation like @Component.

Buy Now
Questions 13

Which two statements describe the ApplicationContext correctly? (Choose two.)

Options:

A.

The ApplicationContext is the root interface for accessing the Spring container.

B.

The ApplicationContext lazy initializes beans by default.

C.

The ApplicationContext can be created in a test environment, web application, and in a standalone application.

D.

The ApplicationContext does not include all functionality of the BeanFactory.

E.

The ApplicationContext maintains singleton beans that are instantiated by the Spring runtime.

Buy Now
Questions 14

Which two statements are correct regarding Spring Boot auto-configuration customization? (Choose two.)

Options:

A.

Use the @AutoConfigureAfter or @AutoConfigureBefore annotations to apply configuration in a specific order.

B.

Disable specific auto-configuration classes by using the exclude attribute on the

@EnableAutoConfiguation annotation.

C.

Provide customized auto-configuration by subclassing the provided Spring Boot auto-configuration classes.

D.

Enable component scanning within auto-configuration classes to find necessary components.

E.

Control the order of auto-configuration classes applied with @AutoConfigureOrder.

Buy Now
Questions 15

Which two statements are true about Spring AOP? (Choose two.)

Options:

A.

The @After advice type is invoked regardless of whether a method successfully returned or an exception was thrown.

B.

In Spring AOP, a join point represents a method execution or property access.

C.

Spring AOP does not use AspectJ ' s pointcut expression language.

D.

Examples of cross-cutting concerns include security, caching, transaction.

E.

There are in total 4 types of advice, @Before, @After, @AfterReturning and @AfterThrowing.

Buy Now
Questions 16

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.)

Options:

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.

Buy Now
Questions 17

What are the two reasons Spring be used to build a Java application? (Choose two.)

Options:

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.

Buy Now
Questions 18

Refer to the exhibit.

2V0-72.22 Question 18

Which two statements are correct regarding the HelloAutoConfig auto-configuration class when it is specified in the META-INF/spring.factories file? (Choose two.)

Options:

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.

Buy Now
Questions 19

Which two options are valid optional attributes for Spring’s @Transactional annotation? (Choose two.)

Options:

A.

isolation

B.

writeOnly

C.

nestedTransaction

D.

readWrite

E.

propagation

Buy Now
Questions 20

Which statement is true? (Choose the best answer.)

Options:

A.

@ActiveProfiles is a class-level annotation that is used to instruct the Spring TestContext Framework to record all application events that are published in the ApplicationContext during the execution of a single test.

B.

@ActiveProfiles is a class-level annotation that you can use to configure how the Spring TestContext Framework is bootstrapped.

C.

@ActiveProfiles is a class-level annotation that you can use to configure the locations of properties files and inlined properties to be added to the set of PropertySources in the Environment for an ApplicationContext loaded for an integration test.

D.

@ActiveProfiles is a class-level annotation that is used to declare which bean definition profiles should be active when loaded an ApplicationContext for an integration test.

Buy Now
Questions 21

Which statement defines a pointcut? (Choose the best answer.)

Options:

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.

Buy Now
Questions 22

Which strategy is correct for configuring Spring Security to intercept particular URLs? (Choose the best answer.)

Options:

A.

The URLs can be specified via configuration (using authorizeRequests () and request matchers), with the most specific rule first and the least specific last.

B.

Spring Security can obtain URLs from Spring MVC controllers, the Spring Security configuration just needs a reference to the controller to be protected.

C.

The URLs are specified in a special properties file, used by Spring Security.

D.

The URLs can be specified via configuration (using authorizeRequests () and request matchers), with the least specific rule first and the most specific last.

Buy Now
Questions 23

Given an ApplicationContext containing three bean definitions of type Foo with bean ids foo1, foo2, and foo3, which three @Autowired scenarios are valid and will allow the ApplicationContext to initialize successfully? (Choose three.)

Options:

A.

@Autowired public void setFoo (Foo foo) {…}

B.

@Autowired @Qualifier (“foo3”) Foo foo;

C.

@Autowired public void setFoo (@Qualifier (“foo1”) Foo foo) {…}

D.

@Autowired private Foo foo;

E.

@Autowired private Foo foo2;

F.

@Autowired public void setFoo(Foo foo2) {…}

Buy Now
Exam Code: 2V0-72.22
Exam Name: Professional Develop VMware Spring
Last Update: Apr 30, 2026
Questions: 79

PDF + Testing Engine

$63.52  $181.49

Testing Engine

$50.57  $144.49
buy now 2V0-72.22 testing engine

PDF (Q&A)

$43.57  $124.49
buy now 2V0-72.22 pdf