From the course: Spring: Spring MVC
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Request and session attributes
- [Narrator] Now that we have plugged in the log in interceptor in our H plus application. We are free to execute the remaining pieces of this demo. But before that let's take a quick look at how do you access the session and request attributes in your Spring MVC application. Now generally in a web application, storing data in HTTP session and request objects is a very common practice. When you have an incoming request, which could go to multiple controllers you need to access data across those controllers until the request gets completed. That data will alive until the request is completed processing. Similarly you can also store data in the HTTP session object which will be available across multiple requests until the session terminates. So playing around in floating data in request and session objects is quite an integral part of any web application. So how do you do that in Spring MVC? There is an…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
-
(Locked)
Introduction to interceptors3m 28s
-
(Locked)
Built-in and custom interceptors2m 45s
-
(Locked)
Add interceptor class5m 45s
-
(Locked)
Register interceptors3m 17s
-
(Locked)
Request and session attributes1m 57s
-
(Locked)
Save and get SessionAttributes demo6m 47s
-
(Locked)
Test session flow and implement forwarding7m 37s
-
(Locked)
End HttpSession8m 33s
-
(Locked)
Redirecting outside an application3m 40s
-
(Locked)
Introduction to themes1m 48s
-
(Locked)
Define themes and theme resolver4m 18s
-
(Locked)
Define ThemeChangeInterceptor6m 38s
-
(Locked)
Pick themes on JSPs2m 37s
-
(Locked)
Introduction to l10n and i18n3m
-
(Locked)
Automatic locale resolution demo9m 55s
-
(Locked)
CookieLocaleResolver and interceptor for l10n and i18n5m 37s
-
(Locked)
-
-