I'm working with Spring 3 MVC (I'm quite new to it...) and I need some database info to be loaded after user's loggin and stay available until user logs out or closes the web page (I could query the DB each time I need it but it wouldn't be efficient). As far as I know, this should be done through session's management. I've found the following tutorial for managing session data:
http://richardchesterwood.blogspot.com.es/2011/03/using-sessions-in-spring-mvc-including.html
Do you think this is a good starting point? Is the 3rd option mentioned the best approach for what I need? When am I supposed to populate the objects that I need to keep in the user's session? Is it OK to do it when the user logs in?
I was also wondering if it is possible to keep some information that should be common to all users (something like a session that is valid for each user).
Thank you very much!!