Meaningless Drivel is fun!
The moose likes Servlets and the fly likes HttpSession and Cookies Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "HttpSession and Cookies" Watch "HttpSession and Cookies" New topic

HttpSession and Cookies

Arjun Reddy
Ranch Hand

Joined: Nov 10, 2007
Posts: 629
Hi All,

Where is the session info stored if we are using HttpSession and Cookies?/


Be Humble... Be Nice.
Uli Hofstoetter
Ranch Hand

Joined: Nov 24, 2006
Posts: 57
The session is stored on the server.

The cookie is stored on the client browser and is used to match the client request to the according session.

SCEA5, Certified ScrumMaster
Angel Taveras
Ranch Hand

Joined: Nov 13, 2008
Posts: 84

Also the session info could be stored in a token in the url. You could do this to disable the session cookie.

[ December 23, 2008: Message edited by: Angel Taveras ]
Arjun Reddy
Ranch Hand

Joined: Nov 10, 2007
Posts: 629
Thanks Uli and Angel for replying
I agree. Here's the link:
subject: HttpSession and Cookies
jQuery in Action, 3rd edition