Spring MVC Interview Questions and Answers
Q. What is Spring Security?
Q. What is Model 1 and Model 2 architecture in Spring MVC?
Q. Can you explain a simple flow in Spring MVC?
Q. What is ModelAndView?
Q. What is a RequestMapping?
Q. What is Dispatcher Servlet?
Q. How is validation done using Spring MVC?
Q. What is BindingResult?
Q. What is a Path Variable?
Q. What is a Model Attribute?
Q. What is a Session Attribute?
Q. What is a init binder?
Q. What is the default scope of bean in Spring framework?
Q. Is Singleton beans are thread safe in Spring Framework?
Q. What is Bean Factory?
Q. Name the various modules used in spring framework?
Q. Explain the RowCallbackHandler in Spring?
Q. Define Application context module?
Q. State the differences between ApplicationContext and BeanFactory in spring?
Q. What are the different types of events of Listeners?
Q. Write about Core container module?
Q. What is AOP module?
Q. What is AOP Alliance?
Q. What are different types of Autowire?
Q. What are the types of the transaction management that is supported by spring?
Q. What is an Aspect?
Q. What is a Joinpoint?
Q. What is called an Advice?
Q. What is a Pointcut?
Q. What is weaving?
Q. What is difference between singleton and prototype bean?
Q. In what points, can weaving be applied?
Q. What are the different types of AutoProxying?
Q. What classes are used to Control the database connection?
Q. What is ‘Throws advice’ in Spring?
Q. What are the various editors used in spring work?
Q. What are the advantages of spring framework?
Q. How is Hibernate accessed using the Spring framework?
Q. What are the various Channels supported by Spring 2.0?
Q. Why is declarative transaction management preferred in Spring?
Q. Explain the concept of a BeanFactory?
Q. What are the different scopes of spring bean?
Q. What are all the ways to access Hibernate by using Spring?
Q. How struts application can be integrated with spring?
Q. What is Inversion of control (IOC)?
Q. Write the benefits of using IOC?
Q. What is Inner bean? What is the drawback of inner bean?
Q. What are the different types of Injection in spring?
Q. What are the benefits of spring framework?
Q. What are the types of Advice?
Q. What is called PreparedStatementCreator?
Q. What is SQLProvider?
Q. Write about BatchPreparedStatementSetter?
Q. What is the better method of using JDBC in Spring?
Q. What exceptions do the DAO classes, use in Spring throw?
Q. Explain the advantages of using DAO module?
Q. Name the significant ApplicationContext implementations used in the spring framework?
Q. How is a bean added to a Spring application?
Q. What are ORM integration modules?
Q. Mention and explain the types of Advice in Spring?
Q. What is the web module?
Q. What is DataAccessException?
Q. What is XMLBeanFactory?
Q. Name the Exception class which is connected to the exceptions thrown by the applications?
Q. Mention the types of lOC (dependency injection)?
Q. What are the important beans lifecycle methods?
Q. How can the default lifecycle methods of beans be nullified?
Q. What is a Target?
Q. Explain the term Proxy?
Q. What is cross cutting concern and concern in spring AOP?
Q. What is Spring MVC framework?
Q. What is DispatcherServlet and ContextLoaderListener?
Q. What is the front controller class of Spring MVC?
Q. How to use Java based configuration?
Q. How can we use Spring to create Restful Web Service returning JSON response?
Q. Can we have multiple Spring configuration files?
Q. Difference between vs ?
Q. Difference between @Component, @Controller, @Repository & @Service annotations?
Q. What does the ViewResolver class?
Q. What is a MultipartResolver and when its used?
Q. How to upload file in Spring MVC Application?
Q. What is Spring MVC Interceptor and how to use it?
Q. How to handle exceptions in Spring MVC Framework?
Q. How to achieve localization in Spring MVC applications?
Q. How to get ServletContext and ServletConfig object in a Spring Bean?
Q. How to use Tomcat JNDI DataSource in Spring Web Application?
Q. How would you relate Spring MVC Framework to 3-tier architecture?
Q. What is Spring Framework?
Q. What are some of the important features and advantages of Spring Framework?
Q. What do you understand by Dependency Injection?
Q. How do we implement DI in Spring Framework?
Q. What are the new features in Spring 5?
Q. What is Spring WebFlux?
Q. Name some of the important Spring Modules?
Q. What do you understand by Aspect Oriented Programming?
Q. What is Aspect, Advice, Pointcut, JointPoint and Advice Arguments in AOP?
Q. What is the difference between Spring AOP and AspectJ AOP?
Q. What is Spring IoC Container?
Q. What is the importance of Spring bean configuration file?
Q. What are different scopes of Spring Bean?
Q. What is Spring Bean life cycle?
Q. How to get ServletContext and ServletConfig object in a Spring Bean?
Q. What is Bean wiring and @Autowired annotation?
Q. What are different types of Spring Bean autowiring?
Q. What is a Controller in Spring MVC?
Q. What’s the difference between @Component, @Repository & @Service annotations in Spring?
Q. What is DispatcherServlet and ContextLoaderListener?
Q. What is ViewResolver in Spring?
Q. What is a MultipartResolver and when it’s used?
Q. How to handle exceptions in Spring MVC Framework?
Q. How to create ApplicationContext in a Java Program?
Q. Can we have multiple Spring configuration files?
Q. What is ContextLoaderListener?
Q. What are the minimum configurations needed to create Spring MVC application?
Q. How would you relate Spring MVC Framework to MVC architecture?
Q. How to achieve localization in Spring MVC applications?
Q. How can we use Spring to create Restful Web Service returning JSON response?
Q. What are some of the important Spring annotations you have used?
Q. Can we send an Object as the response of Controller handler method?
Q. How to upload file in Spring MVC Application?
Q. What is Spring MVC Interceptor and how to use it?
Q. What is Spring JdbcTemplate class and how to use it?
Q. How to use Tomcat JNDI DataSource in Spring Web Application?
Q. How would you achieve Transaction Management in Spring?
Q. How to integrate Spring and Hibernate Frameworks?
Q. How to inject a java.util.Properties into a Spring Bean?
Q. Name some of the design patterns used in Spring Framework?