Implementing MVC Design Patterns

A rigorous set of recipes on how to kick off Spring 5.0 projects verified that the core platform is still composed of almost the same APIs found in its previous version. Even though Spring 5.0 promotes the new functional and reactive web framework, it still upholds the traditional annotations and web APIs such as @Controller, @RequestMapping, @Bean, the ApplicationContext interface, and many other old features such JSR-330 annotations.

Now, we focus on how the basic MVC components are written if Spring 5.0 is used. We will observe the differences and similarities between Spring 5.0 and the other versions especially when creating data sources, the Data Access Object (DAO) layer, service layers, validation, and other types of request handling.

In this chapter, you will learn the following:

  • Creating a simple @Controller
  • Creating a simple @Controller with method-level URL mapping
  • Designing a simple form @Controller
  • Creating a multi-action @Controller
  • Form validation and parameter type conversion
  • Creating request- and session-scoped beans
  • Implementing page redirection and Flash-scoped beans
  • Creating database connection pooling
  • Implementing the DAO layer using the Spring JDBC Framework
  • Creating a service layer in an MVC application
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
52.14.82.217