Following quiz provides Multiple Choice Questions (MCQs) related to Spring Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
Q 1 - Which of the statement is not correct?
All of the above statements are correct.
Q 2 - What is bean scope?
Bean scope instructs Spring Container to produce a new bean instance as per the scope defined.
Q 3 - What is global-session scope?
global-session scope instructs Spring IoC container to create a instance per HTTP application.
Q 4 - What does @Required annotation mean?
@Required annotation simply indicates that the affected bean property must be populated at configuration time, through an explicit property value in a bean definition or through autowiring.
Q 5 - What is ContextStartedEvent event?
ContextStartedEvent event is published when the ApplicationContext is started using the start() method on the ConfigurableApplicationContext interface.
Q 6 - How before advice works?
before advice runs before a method execution.
Q 7 - Which of the following is part of Data Access layer in Spring framework?
JMS is the part of Data Access layer in Spring framework.
Q 8 - If a bean is created once per Ioc Container, scope is
If a bean is created once per Ioc Container, scope is singleton.
Q 9 - How to handle shut down of IoC container?
Using registerShutdownHook() method, shut down of IoC container can be handled. Other methods do not exists.
A bean can be configured to have an inner bean.