collection of questions for spring
collection of questions for spring
Rajeev Gupta
rgupta.mtech@gmail.com
Java Trainer & consultant
@rajeev_gupta76
Spring
Spring?
●
What is Loose Coupling?
●
What is a Dependency?
●
What is IOC (Inversion of Control)?
●
What is Dependency Injection?
●
Can you give few examples of Dependency Injection?
●
What is Auto Wiring?
●
What are the important roles of an IOC Container?
●
What are Bean Factory and Application Context?
● Can you compare Bean Factory with Application Context?
●
How do you create an application context with Spring?
Spring?
● How does Spring know where to search for
Components or Beans?
● What is a Component Scan?
● How do you define a component scan in XML and
Java Configurations?
● How is it done with Spring Boot?
● What does @Component signify?
● What does @Autowired signify?
Spring?
● What’s the difference Between @Controller, @Component,
@Repository, and @Service Annotations in Spring?
● What is the default scope of a bean?
● Are Spring beans thread safe?
● What are the other scopes available?
● How is Spring’s singleton bean different from Gang of Four
Singleton Pattern?
● What are the different types of dependency injections?
● What is setter injection?
Spring?
● What is constructor injection?
● How do you choose between setter and constructor
injections?
● What are the different options available to create Application
Contexts for Spring?
● What is the difference between XML and Java
Configurations for Spring?
● How do you choose between XML and Java Configurations
for Spring?
● How does Spring do Autowiring?
Spring?
● What are the different kinds of matching used by Spring for
Autowiring?
● How do you debug problems with Spring Framework?
● How do you solve NoUniqueBeanDefinitionException?
● How do you solve NoSuchBeanDefinitionException?
● What is @Primary?
● What is @Qualifier?
● What is CDI (Contexts and Dependency Injection)?
● Does Spring Support CDI?
Spring?
● Would you recommed to use CDI or Spring
Annotations?
● What are the major features in different versions
of Spring?
● What are new features in Spring Framework 4.0?
● What are new features in Spring Framework 5.0?
● What are important Spring Modules?
● What are important Spring Projects?
Spring?
● What is the simplest way of ensuring that we are
using single version of all Spring related
dependencies?
● Name some of the design patterns used in Spring
Framework?
● What do you think about Spring Framework?
● Why is Spring Popular?
● Can you give a big picture of the Spring Framework?
Spring MVC
Spring MVC
● What is Model 1 architecture?
● What is Model 2 architecture?
● What is Model 2 Front Controller architecture?
● Can you show an example controller method in
Spring MVC?
● Can you explain a simple flow in Spring MVC?
● What is a ViewResolver?
Spring MVC
● What is Model?
● What is ModelAndView?
● What is a RequestMapping?
● What is Dispatcher Servlet?
● How do you set up Dispatcher Servlet?
● What is a form backing object?
● How is validation done using Spring MVC?
● What is BindingResult?
● How do you map validation results to your view?
Spring MVC
● What are Spring Form Tags?
● What is a Path Variable?
● What is a Model Attribute?
● What is a Session Attribute?
● What is a init binder?
● How do you set default date format with
Spring?
Spring Boot
Spring boot
● What is Spring Boot?
● What are the important Goals of Spring Boot?
● What are the important Features of Spring
Boot?
● Compare Spring Boot vs Spring?
● Compare Spring Boot vs Spring MVC?
Spring boot
● What is the importance of @SpringBootApplication?
● What is Auto Configuration?
● How can we find more information about Auto
Configuration?
● What is an embedded server? Why is it important?
● What is the default embedded server with Spring
Boot?
● What are the other embedded servers supported by
Spring Boot?
Spring boot
● What are Starter Projects?
● Can you give examples of important starter
projects?
● What is Starter Parent?
● What are the different things that are defined in
Starter Parent?
● How does Spring Boot enforce common
dependency management for all its Starter projects?
Spring boot
● What is Spring Initializr?
● What is application.properties?
● What are some of the important things that can
customized in application.properties?
● How do you externalize configuration using Spring
Boot?
● How can you add custom application properties using
Spring Boot?
● What is @ConfigurationProperties?
Spring boot
● What is a profile?
● How do you define beans for a specific profile?
● How do you create application configuration for
a specific profile?
● How do you have different configuration for
different environments?
● What is Spring Boot Actuator?
Spring boot
●