Home
MCQS
Spring Boot MCQ Quiz Hub
Spring MCQs
Choose a topic to test your knowledge and improve your Spring Boot skills
1. Which method is used to gracefully shutdown all the bean processes after closing the spring container?
shutdownHook
destory method
none of the mentioned
all of the mentioned
2. Which attribute is used to specify classname of the bean?
name
id
class
constructor-args
3. Declaring bean form object properties can be done using:-
PropertyPathFactoryBean
util:constant
None of the mentioned
All of the mentioned
4. What are the ways to create custom Property Editors?
implement PropertyEditor interface
extend PropertyEditorSupport Class
none of the mentioned
all of the mentioned
5. Which package is used for periodic work
java.lang.Thread
java.util.TimerTask
java.util.Timer
java.util.concurrent
6. Method used to process bean before initialization callback
scope
postProcessAfterInitialization()
postProcessBeforeInitialization()
it's own constructor
7. Which attribute is used to set the scope of the bean?
setScope
scope
getScope
none of the mentioned
8. Method used to process bean before initialization callback
scope
postProcessAfterInitialization
postProcessBeforeInitialization()
it's own constructor
9. Which attribute is used to set the scope of the bean?
setScope
scope
getScope
None of the mentioned
10. Which tag is also allowed by static field?
util:constant
list
set
constructor-args
Submit