March Special Sale - Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: mxmas70

Home > VMware > VCP-AM Develop 2022 > 2V0-72.22

2V0-72.22 Professional Develop VMware Spring Question and Answers

Question # 4

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.

Full Access
Question # 5

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.

Full Access
Question # 6

Refer to the exhibit.

Which two statements are correct regarding the HelloAutoConfig auto-configuration class when it isspecified 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.

Full Access
Question # 7

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

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.

Full Access
Question # 8

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.

Full Access
Question # 9

Which two statements about the @Autowired annotation are true? (Choose two.)

A.

@Autowired fields are injected after any config methods are invoked.

B.

Multiple arguments can be injected into a single method using @Autowired.

C.

By default, if a dependency cannot be satisfied with @Autowired, Spring throws a RuntimeException.

D.

If @Autowired is used on a class, field injection is automatically performed for all dependencies.

E.

@Autowired can be used to inject references into BeanPostProcessor and

BeanFactoryPostProcessor.

Full Access