What are the best practices of Spring Framework?

In Spring Framework, following are some of the best practices: We can Divide spring bean configurations based on their concerns

How will you handle exceptions in Spring MVC Framework?

Spring MVC Framework provides following mechanisms to help us achieve exception handling:

What is the difference between DispatcherServlet and ContextLoaderListener in Spring?

DispatcherServlet is the core of Spring MVC application. It loads Spring bean configuration file and initialize all the beans mentioned

What are the different types of events provided by Spring framework?

Spring framework provides following five events for Context: ContextRefreshedEvent: Whenever ApplicationContext is initialized or refreshed, Spring publishes this event. We

How can you upload a file in Spring MVC Application?

In Spring MVC framework we can use MultipartResolver interface to upload a file. We need to make configuration changes to

Name some popular Spring framework annotations that you use in your project?

Spring has many Annotations to serve different purposes. For regular use we refer following popular Spring annotations: @Controller: This annotation

In Spring framework, what is the difference between FileSystemResource and ClassPathResource?

In Spring we can specify configuration by using a file or classpath.

What are the differences between Dependency Injection (DI) and Factory Pattern?

Main differences between Dependency Injection (DI) and Factory Pattern are: Coupling: Factory pattern adds tight coupling between an object, factory

What are the drawbacks of Setter based Dependency Injection (DI) in Spring?

Although Setter based Dependency Injection has higher priority than Constructor based DI, there are some disadvantages of it. No Guarantee: