Winter Sale - Special Limited Time 65% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: dpm65

2V0-72.22 Professional Develop VMware Spring Questions and Answers

Questions 4

Which two statements are true about Spring Boot and Spring Data JPA? (Choose two.)

Options:

A.

@EntityScan and spring.jpa.* properties can be used to customize Spring Data JPA.

B.

Any kind of Hibernate property can be passed to Spring Data JPA like spring.jpa.properties.xxx.

C.

Spring Data JPA is the only implementation for relational databases.

D.

Scanning of JPA Entities can not be customized, the whole classpath is scanned.

E.

Embedded Databases (H2, HSQLDB, Derby) are not re-created during the startup.

Buy Now
Questions 5

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

Options:

A.

@SqlMergeMode(false)

B.

@Rollback(false)

C.

@Commit

D.

@Sql(alwaysCommit=true)

E.

@Transactional(commit=true)

Buy Now
Questions 6

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 7

Refer to the exhibit.

2V0-72.22 Question 7

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

Options:

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.

Buy Now
Questions 8

Which two statements are true regarding @WebMvcTest? (Choose two.)

Options:

A.

It auto-configures a MockMvc.

B.

It will only scan for @Controller beans in the source code.

C.

It is used for testing Spring MVC components such as @Controller with a running server.

D.

Typically it is used in combination with @MockBean when there is a dependency bean to be mocked.

E.

It is typically used with @ExtendWith(MockitoExtension.class) in JUnit 5.

Buy Now
Questions 9

Which two statements are true regarding the RestTemplate class? (Choose two.)

Options:

A.

It supports asynchronous non-blocking model.

B.

It automatically supports sending and receiving Java objects.

C.

It provides convenience methods for writing REST clients.

D.

It provides convenience methods for writing REST services.

E.

Sending an HTTP request with a custom header is not possible when using RestTemplate.

Buy Now
Questions 10

Which two statements are true about REST? (Choose two.)

Options:

A.

REST is a Protocol.

B.

REST is Stateful.

C.

REST is Reliable.

D.

REST is Interoperable.

E.

REST is Relative.

Buy Now
Questions 11

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 12

Which three dependencies are provided by the spring-boot-starter-test? (Choose three.)

Options:

A.

Cucumber

B.

Hamcrest

C.

spring-test

D.

Junit

E.

EasyMock

F.

PowerMock

Buy Now
Questions 13

Which two statements are true regarding Spring Boot Testing? (Choose two.)

Options:

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.

Buy Now
Questions 14

Spring Boot will find and load property files in which of the following? (Choose the best answer.)

Options:

A.

A *.properties file matching the name of the class annotated with @SpringBootApplication.

B.

config.properties or config.yml, usually located in the classpath root.

C.

application.properties or application.yml, usually located in the classpath root.

D.

env.properties or env.yml, usually located in the classpath root.

Buy Now
Questions 15

Which three types can be used as @Controller method arguments? (Choose three.)

Options:

A.

Locale

B.

Principal

C.

Language

D.

Session

E.

Request

F.

HttpSession

Buy Now
Questions 16

Which two statements are true regarding bean creation? (Choose two.)

Options:

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.

Buy Now
Questions 17

Refer to the exhibit.

It is a Java code fragment from a Spring application. Which statement is true with regard to the above example? (Choose the best answer.)

Options:

A.

This syntax is invalid because the result of the getBean() method call should be cast to ClientService.

B.

It will return a bean called ClientService regardless of its id or name.

C.

This syntax is invalid because the bean id must be specified as a method parameter.

D.

It will return a bean of the type ClientService regardless of its id or name.

Buy Now
Questions 18

Refer to the exhibit.

2V0-72.22 Question 18

Which two statements are correct regarding auto-configuration of DataSource and JdbcTemplate beans given a Spring Boot application with only these two dependencies? (Choose two.)

Options:

A.

A DataSource bean will not be auto-configured.

B.

A JdbcTemplate bean will not be auto-configured.

C.

A JdbcTemplate bean will be auto-configured.

D.

A DataSource bean will be auto-configured only if a JdbcTemplate bean is explicitly defined.

E.

A DataSource bean will be auto-configured.

Buy Now
Questions 19

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 20

Which two statements are true concerning constructor injection? (Choose two.)

Options:

A.

If there is only one constructor the @Autowired annotation is not required.

B.

Constructor injection only allows one value to be injected.

C.

Constructor injection is preferred over field injection to support unit testing.

D.

Construction injection can be used with multiple constructors without @Autowired annotation.

E.

Field injection is preferred over constructor injection from a unit testing standpoint.

Buy Now
Questions 21

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 22

Which two options are REST principles? (Choose two.)

Options:

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.

Buy Now
Questions 23

Which two statements are correct regarding the differences between @ConfigurationProperties and @Value? (Choose two.)

Options:

A.

@Value must be used for environment variables, as @ConfigurationProperties cannot access the environment.

B.

@Value supports relaxed binding of properties, but not property binding through SpEL.

C.

@ConfigurationProperties is preferable over @Value when type-safety during property binding is a concern.

D.

@ConfigurationProperties only bind properties from .properties files, not from .yml files.

E.

@ConfigurationProperties supports relaxed binding of properties, but not property binding through SpEL.

Buy Now
Exam Code: 2V0-72.22
Exam Name: Professional Develop VMware Spring
Last Update: Dec 7, 2024
Questions: 79

PDF + Testing Engine

$57.75  $164.99

Testing Engine

$43.75  $124.99
buy now 2V0-72.22 testing engine

PDF (Q&A)

$36.75  $104.99
buy now 2V0-72.22 pdf
dumpsmate guaranteed to pass
24/7 Customer Support

DumpsMate's team of experts is always available to respond your queries on exam preparation. Get professional answers on any topic of the certification syllabus. Our experts will thoroughly satisfy you.

Site Secure

mcafee secure

TESTED 12 Dec 2024