Forums Register Login

session object

+Pie Number of slices to send: Send
I am creating session object in my servlet program ,, but when I make a request to a servlet by opening 2 browser it is taking as only one session object.. It is happening only in my latop, in other places if I make a request from 2 browser 2 session objects are getting created, I am using session.getId() to check the ID of session,

Please help me thanks
+Pie Number of slices to send: Send
Internally JSESSIONID cookie is passed in each request to Web Server to identify the session object exclusively allocated for the Client...

If you open a new window or new tab from the existing browser parent window, same JSESSIONID is passed... So it will refer to the same session object...

When you do open a separate new Browser window, a new request is created to the web server and different JSESSIONID is created by Web server and sends as Cookie to the Client...Then, JSESSIONID cookie is sent at subsequent requests to the Server
+Pie Number of slices to send: Send
Different browsers handle new windows differently; some create new sessions, some don't, some are configurable to do either.
+Pie Number of slices to send: Send
Thank you
+Pie Number of slices to send: Send
 

sagar shiraguppi wrote:I am creating session object in my servlet program ,, but when I make a request to a servlet by opening 2 browser it is taking as only one session object.. It is happening only in my latop, in other places if I make a request from 2 browser 2 session objects are getting created, I am using session.getId() to check the ID of session,

Please help me thanks


I agree with David. But, why is this? Is this really happening?
+Pie Number of slices to send: Send
 

It is happening only in my latop only



whats your Laptop company and its configuration ?? just kiding .

+Pie Number of slices to send: Send
yes it is happening with only my laptop, i tried with other laptop who are running on Vista, but only in my laptop this problem, other than this program no issues with any other program, I m still not clear why not only one session is created when I open two browser of same vendor and send a request, If I open say one chrome browser and other IE and sends the request two session are getting created understandably.. But issue is with same two browser and only one session object..
Who knew that furniture could be so violent? Put this tiny ad out there to see what happens:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 1479 times.
Similar Threads
Why does it take 2 requests to set session attribute?
URGENT!!
How to automatically display SessionExpired.jsp upon session timeout ?
problem of passing parameter
request dispatcher
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 19, 2024 04:54:36.