[2022年04月12日]2V0-72.22のPDFで最近更新された問題です集試験点数を伸ばそう [Q13-Q37]

Share

[2022年04月12日]2V0-72.22のPDFで最近更新された問題です集試験点数を伸ばそう

2V0-72.22完全版問題集には無料PDF問題で合格させる

質問 13
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.)

  • A. It will return a bean called ClientService regardless of its id or name.
  • B. This syntax is invalid because the result of the getBean() method call should be cast to ClientService.
  • C. It will return a bean of the type ClientService regardless of its id or name.
  • D. This syntax is invalid because the bean id must be specified as a method parameter.

正解: C

 

質問 14
Which two statements are true regarding Spring and Spring Boot Testing? (Choose two.)

  • A. @SpringBootTest or @SpringJUnitConfig can be used for creating an ApplicationContext.
  • B. Mockito spy is not supported in Spring Boot testing by default.
  • C. EasyMock is supported out of the box.
  • D. Integration and slice testing are both supported.
  • E. The spring-test dependency provides annotations such as @Mock and @MockBean.

正解: B,E

 

質問 15
Which two statements are correct regarding the Health Indicator status? (Choose two.)

  • A. The severity order cannot be changed due to security reasons.
  • B. The built-in status values are DOWN, OUT_OF_SERVICE, UNKNOWN, and UP in decreasing order of severity.
  • C. The status with the least severity is used as the top-level status.
  • D. Custom status values can be created.
  • E. The last status in a sorted list of HealthIndicators is used to derive the final system health.

正解: B,D

 

質問 16
Which three statements are advantages of using Spring's Dependency Injection? (Choose three.)

  • A. Dependency injection creates tight coupling between components.
  • B. Dependency injection facilitates loose coupling between components.
  • C. Configuration can be externalized and centralized in a small set of files.
  • D. Dependencies between application components can be managed external to the components.
  • E. Dependency injection can make code easier to trace because it couples behavior with construction.
  • F. Dependency injection reduces the start-up time of an application.

正解: A,C,F

 

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

  • A. Field injection is preferred over constructor injection from a unit testing standpoint.
  • B. If there is only one constructor the @Autowired annotation is not required.
  • 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. Constructor injection only allows one value to be injected.

正解: A,C

 

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

  • A. A class must be annotated with @Service and @Transaction.
  • B. Annotate a class, an interface, or individual methods requiring a transaction with the @Transactional annotation.
  • C. A class requiring a transaction must implement the TransactionInterceptor interface.
  • D. Write a Spring AOP advice to implement transactional behavior.
  • E. Add @EnableTransactionManagement to a Java configuration class.

正解: B,E

 

質問 19
Which two statements are true regarding storing user details in Spring Security? (Choose two.)

  • A. User details can be stored in a database, in LDAP, or in-memory.
  • B. The user details includes username and password but not authorities.
  • C. User details can be stored in custom storage and retrieve them by implementing the UserDetailsService interface.
  • D. With a custom UserDetailsService defined in the ApplicationContext, Spring Boot still creates the default user.
  • E. Passwords must be hashed and the default hashing algorithm is MD5.

正解: B,D

 

質問 20
Which two statements are true regarding @DataJpaTest? (Choose two.)

  • A. TestEntityManager provides all methods that are provided by EntityManager and more.
  • B. It can be used for testing JdbcTemplate.
  • C. It auto-configures a TestEntityManager bean.
  • D. If an embedded database is on the classpath, it will be used to configure a DataSource by default.
  • E. It can be used for testing both JPA components and NoSQL components.

正解: C,D

 

質問 21
Refer to the exhibit.

Assume that the application is using Spring transaction management which uses Spring AOP internally.
Choose the statement that describes what is happening when the update1 method is called? (Choose the best answer.)

  • A. There is only one transaction initiated by update1() because the call to update2() does not go through the proxy.
  • B. There is only one transaction because REQUIRES_NEW will use an active transaction if one already exists.
  • C. An exception is thrown as another transaction cannot be started within an existing transaction.
  • D. There are 2 transactions because REQUIRES_NEW always runs in a new transaction.

正解: A

 

質問 22
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.)

  • A. @Autowired public void setFoo (@Qualifier ("foo1") Foo foo) {...}
  • B. @Autowired @Qualifier ("foo3") Foo foo;
  • C. @Autowired public void setFoo (Foo foo) {...}
  • D. @Autowired private Foo foo;
  • E. @Autowired public void setFoo(Foo foo2) {...}
  • F. @Autowired private Foo foo2;

正解: C,D,E

 

質問 23
Which two options are valid optional attributes for Spring's @Transactional annotation? (Choose two.)

  • A. nestedTransaction
  • B. propagation
  • C. readWrite
  • D. writeOnly
  • E. isolation

正解: B,E

 

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

  • A. Multiple arguments can be injected into a single method using @Autowired.
  • B. By default, if a dependency cannot be satisfied with @Autowired, Spring throws a RuntimeException.
  • C. If @Autowired is used on a class, field injection is automatically performed for all dependencies.
  • D. @Autowired can be used to inject references into BeanPostProcessor and
  • E. @Autowired fields are injected after any config methods are invoked.

正解: A,D

解説:
BeanFactoryPostProcessor.

 

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

  • A. prototype
  • B. session
  • C. singleton
  • D. request

正解: C

 

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

  • 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. Embedded Databases (H2, HSQLDB, Derby) are not re-created during the startup.
  • D. Scanning of JPA Entities can not be customized, the whole classpath is scanned.
  • E. Spring Data JPA is the only implementation for relational databases.

正解: C,E

 

質問 27
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.)

  • A. Ensure a valid @ComponentScan annotation in the Java configuration is specified.
  • B. Ensure a valid @Scope for the class is specified.
  • C. Ensure a valid bean name in the @Component annotation is specified.
  • D. Ensure a valid @Bean for the class is specified.

正解: C

 

質問 28
Which two statements are true concerning the BeanPostProcessor Extension point? (Choose two.)

  • A. BeanPostProcessors are called before the dependencies have been injected.
  • B. BeanPostProcessors are called before the BeanFactoryPostProcessors.
  • C. BeanPostProcessors cannot be ordered in a Spring Boot application.
  • D. BeanPostProcessors are called during the initialization phase of a bean life cycle.
  • E. Custom BeanPostProcessors can be implemented for Spring applications.

正解: D,E

 

質問 29
Which two statements are true regarding a Spring Boot-based Spring MVC application? (Choose two.)

  • A. The default port of the embedded servlet container is 8088.
  • B. Spring Boot starts up an embedded servlet container by default.
  • C. Spring MVC starts up an in-memory database by default.
  • D. Jetty is the default servlet container.
  • E. The default embedded servlet container can be replaced with Undertow.

正解: B,D

 

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

  • A. To provide a logout capability.
  • B. To drive authentication.
  • C. To manage application users.
  • D. To enforce authorization (access control).
  • E. To encrypt data.
  • F. To provide risk governance.

正解: A,B,D

 

質問 31
Refer to the exhibit.

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

  • A. Add @RequestParam("id") String accountId argument to the update() handler method.
  • B. Add @RequestParam long accountId argument to the update() handler method.
  • C. Add @PathVariable long accountId argument to the update() handler method.
  • D. Add @PathVariable("id") String accountId argument to the update() handler method.

正解: D

 

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

  • A. Allow access to a method based on HTTP method.
  • B. Allow access to a method based on user identity.
  • C. Allow access to a method based on request URL.
  • D. Allow access to a method based on the returned object.
  • E. Allow access to a method based on roles.

正解: A,E

 

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

  • A. REST is Stateful.
  • B. REST is a Protocol.
  • C. REST is Interoperable.
  • D. REST is Reliable.
  • E. REST is Relative.

正解: B,C

 

質問 34
Refer to the exhibit.

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

  • A. An implementation of this repository can be automatically generated by Spring Data JPA.
  • B. CustomerRepository should be a class, not an interface.
  • C. A class that implements CustomerRepository must be implemented and declared as a Spring Bean.
  • D. JPA annotations are required on the Customer class to successfully use Spring Data JDBC.

正解: A

 

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

  • A. Spring Security can obtain URLs from Spring MVC controllers, the Spring Security configuration just needs a reference to the controller to be protected.
  • B. The URLs can be specified via configuration (using authorizeRequests () and request matchers), with the most specific rule first and the least specific last.
  • 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.

正解: B

 

質問 36
Which statement is true about the @PropertySource annotation? (Choose the best answer.)

  • A. Used to designate the location of the application.properties file in a Spring Boot application.
  • B. Used to designate the file directory of the application.properties file in a Spring Boot application.
  • C. Used to add a set of name/value pairs to the Spring Environment from an external source.
  • D. Used to easily look up and return a single property value from some external property file.

正解: D

 

質問 37
......


VMware 2V0-72.22 認定試験の出題範囲:

トピック出題範囲
トピック 1
  • Describe the basic request processing lifecycle for REST requests
  • Explain and use Annotation-based Configuration
トピック 2
  • Use Spring Security to configure Authentication and Authorization
  • Annotation-Based Configuration and Component Scanning
トピック 3
  • Describe Spring Boot dependency management
  • Explain how to create a Spring MVC application using Spring Boot
トピック 4
  • Create controllers to support the REST endpoints for various verbs
  • Access Beans in the Application Context
トピック 5
  • Describe how Spring determines bean creation order
  • Implement and deploy Advices using Spring AOP
トピック 6
  • Use External Properties to control Configuration
  • Discuss Best Practices for Configuration choices
トピック 7
  • Create a simple RESTful controller to handle GET requests
  • Execute queries using callbacks to handle result sets
トピック 8
  • Describe and use Spring Transaction Management
  • Use the Spring Expression Language (SpEL)
トピック 9
  • Describe options for defining and loading properties
  • Explain how Spring proxies add behavior at runtime
トピック 10
  • Explain the concepts behind AOP and the problems that it solves
  • Demonstrate the purpose of Profiles

 

100%更新されたのはVMware 2V0-72.22限定版PDF問題集:https://www.goshiken.com/VMware/2V0-72.22-mondaishu.html