O'Reilly logo

Spring Persistence with Hibernate by Ahmad Seddighi

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

This chapter discussed how to use Spring in web applications. We started with a quick overview of the MVC pattern. Our discussion continued with the common configuration to integrate web frameworks with Spring. We used the org.springframework.web.context.ContextLoaderListener class to load the Spring application context at application startup, and then store it in the ServletContext. In any JSP page or servlet class, the stored ApplicationContext can be accessed through Spring utility class: org.springframework.web.util.WebApplicationContextUtils.

To develop a web application with the Spring MVC framework, you must configure the DispatcherServlet as the front controller. DispatcherServlet accepts all web requests, and forwards each to ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required