Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Session Mgmt (URL rewriting)

 
Manwatkar Vaibhav
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
This is my first post in this forum.. I have a query releated to Session Management..

When the container gets a request from the client for the first time, it checks for request.getSession(). It won't get any Session Id, so for the first time, it will create a Session, associate a Session Id. Further it will add a Cookie to the response to set the Session Id as well as say the servlet does URL rewriting by which the Session Id is also appended to the request URL.. This response is sent to the Client.. Now when the same client (with Cookies disabled) makes the second request, still, there will be no Session Id in the request.. So it looks for URL to get the Session Id.

The question is, in both requests (1st & 2nd), it gets no Session Id. But 2nd time it looks for request URL to get the Session Id. How does it looks for request URL for 2nd time..?

I hope I am not asking wrong question..

Please explain me if any body knows the answer..
 
Vipul Tulsulkar
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
If you have a copy of Head first JSP & servlets then please go through
Pg.no.236.Even after that you have any doubts then please let me know.

Vipul
SCWCD 1.4
SCJP 1.4
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic