The following article explains What is Spring MVC.

Basically, Spring MVC (Model-View-Controller) is a web framework that Spring provides for building web applications. In fact, it is a popular and widely used framework that follows the MVC design pattern and provides a powerful and flexible mechanism for developing web-based applications. The following are the main components of Spring MVC.

Main Components of Spring MVC

  1. Model. The model means the data and the business logic of the application. So, in Spring MVC, we usually implement the model as a set of Java objects called beans.
  2. View. Similarly, the view renders the data provided by the model. We can implement the views using JSP, Thymeleaf, or other templating engines.
  3. Controller. Likewise, the controller receives requests from the client and is responsible for invoking the appropriate business logic and returning the appropriate view. In fact, controllers are implemented as Java classes annotated with @Controller.
  4. Dispatcher Servlet. Further, the dispatcher servlet is responsible for intercepting all incoming requests and forwarding them to the appropriate controller.
  5. Handler Mapping. Similarly, the handler mapping is responsible for mapping incoming requests to the appropriate controller.
  6. View Resolver. The view resolver is responsible for resolving the view to be rendered based on the controller’s response.

In short, Spring MVC provides a number of features that make it a popular choice for developing web-based applications. Also, it provides robust support for handling HTTP requests and responses, built-in validation support, and support for RESTful web services. Additionally, this framework is highly configurable. Therefore, it can be easily extended to meet the specific needs of a given application.


Further Reading

Spring Framework Practice Problems and Their Solutions

Java Practice Exercise

programmingempire

Princites