Free 2V0-72.22 Exam Braindumps (page: 5)

Page 4 of 16

Refer to the exhibit.



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

  1. Add @PathVariable("id") String accountId argument to the update() handler method.
  2. Add @PathVariable long accountId argument to the update() handler method.
  3. Add @RequestParam long accountId argument to the update() handler method.
  4. Add @RequestParam("id") String accountId argument to the update() handler method.

Answer(s): A


Reference:

https://docs.spring.io/spring-framework/docs/4.3.12.RELEASE/spring-framework- reference/ htmlsingle/



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

  1. The URLs can be specified via configuration (using authorizeRequests () and request matchers), with the most specific rule first and the least specific last.
  2. Spring Security can obtain URLs from Spring MVC controllers, the Spring Security configuration just needs a reference to the controller to be protected.
  3. The URLs are specified in a special properties file, used by Spring Security.
  4. The URLs can be specified via configuration (using authorizeRequests () and request matchers), with the least specific rule first and the most specific last.

Answer(s): A


Reference:

https://www.baeldung.com/security-none-filters-none-access-permitAll



In which three ways are Security filters used in Spring Security? (Choose three.)

  1. To provide risk governance.
  2. To drive authentication.
  3. To manage application users.
  4. To provide a logout capability.
  5. To enforce authorization (access control).
  6. To encrypt data.

Answer(s): B,D,E


Reference:

https://www.javadevjournal.com/spring-security/spring-security-filters/



Refer to the exhibit.



The above code shows a conditional @Bean method for the creation of a JdbcTemplate bean.
Which two statements correctly describe the code behavior? (Choose two.)

  1. @ConditionalOnBean(name= "dataSource") should be replaced with @ConditionalOnBean (DataSource.class) for greater flexibility.
  2. @ConditionalOnBean(name= "dataSource") should be replaced with @ConditionalOnMissingBean (DataSource.class) for greater flexibility.
  3. The @Bean annotation should be removed.
  4. A JdbcTemplate bean will be created when the DataSource class is in the classpath but there is no DataSource bean.
  5. A JdbcTemplate bean will be created when a bean named dataSource has already been created.

Answer(s): A,D






Post your Comments and Discuss VMware 2V0-72.22 exam with other Community members:

2V0-72.22 Discussions & Posts