• Post Reply Bookmark Topic Watch Topic
  • New Topic

sessions  RSS feed

 
vianyrajnish rajnish
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all ,


Can any one give me example scenario in which there could be a more than one request at the same time , from the same client?

( My question is related to session attributes and thread safe )



Vinay Rajnish
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Two windows open ?
 
vianyrajnish rajnish
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Satou kurinosuke,

For an web application, user can open two windows ... does that mean two requests from a client? .. and client can do two works simultaneously?...
please clear this doubt...


Vinay Rajnish
 
Rahul Bhattacharjee
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by vianyrajnish rajnish:
( My question is related to session attributes and thread safe )


Session attributes are not thread safe.If you make request to web application from two different browser instances then there would be two sessions.

Consider this scenario.

You are already communicating with a web application (already in session ) and right click on its link and select open in new window.In this case the JSESSIONID which identifies the session will also get copied and both the browsers would make no difference to the server.
[ June 26, 2007: Message edited by: Rahul Bhattacharjee ]
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Some other examples would be pages with frames and pages that make AJAX requests.
 
Amit M Tank
Ranch Hand
Posts: 257
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Using Iframes in your html pages will make more than one request to the server for the same browser instance.
 
vianyrajnish rajnish
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

ok ...I got it now..
thanks all who replied and for helping out..

Thanks ,
Vinay Rajnish
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!