2v0-7222 Exam QuestionsBrowse all questions from this exam

2v0-7222 Exam - Question 30


Which three statements are advantages of using Spring’s Dependency Injection? (Choose three.)

Show Answer
Correct Answer: BCDEF

Using Spring's Dependency Injection (DI) provides several advantages. Firstly, DI allows for the management of dependencies between application components to be handled externally (C), which means the components themselves do not need to manage the instantiation or lifecycle of their dependencies. Secondly, DI enables the externalization and centralization of configuration (D) into a small set of files, thus simplifying the management of configurations across different environments. Lastly, DI encourages loose coupling between components (F), as dependencies are injected rather than hard coded, making the system more modular and easier to maintain and test.

Discussion

3 comments
Sign in to comment
Tolo01Options: CDF
Jul 31, 2023

I think C, D and F are the best answer

saJAvaOptions: CDF
Jun 10, 2024

correct

rhuanca
Mar 25, 2023

why A and C are wrong ?

nesreenmhd123
Oct 7, 2023

A. is incorrect. Dependency Injection decouples behavior from construction, making it easier to manage and test components independently.