Question about session
Hello All, I have used %@ page session=false % to set the page not to join session, but when I use HttpSession session = request.getSession(false) to get session, I still can get the session that created before. Do you think it is a correct status? Why? Thanks. %@ page session=false % % HttpSession session = request.getSession(false); % Regards, Xiaojing - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Question about session
- Original Message - From: Cui Xiaojing-a13339 [EMAIL PROTECTED] To: Tomcat Developers List [EMAIL PROTECTED] Sent: Wednesday, June 18, 2003 7:38 PM Subject: Question about session Hello All, I have used %@ page session=false % to set the page not to join session, but when I use HttpSession session = request.getSession(false) to get session, I still can get the session that created before. Do you think it is a correct status? Why? Thanks. Yes, this is the correct status. If you want to know why, either read the JSP spec, or ask the question on the tomcat-users list. %@ page session=false % % HttpSession session = request.getSession(false); % Regards, Xiaojing - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Question about Session in Tomcat 3.3
As I tested, when context reloads in Tomcat 3.3.1, e.g. caused by modification of servlet class, sessions are lost. Is it true for all Tomcat 3.3.x? Is there any switch in source code which can change this behavior and maintain sessions through context reloading? Thanks for your help. Hugh __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Question about Session in Tomcat 3.3 -- continued...
I changed switch fullReload in ReloadInterceptor from true to false, and sessions are maintained through context reloading. (Of course, because the old context remains.) Is there any disadvantage if I set this way? Anyway fullReload=true is default setting. Thanks. Hugh __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: Question about Session in Tomcat 3.3 -- continued...
Yes, it seems to be true that sessions are lost on reloading with fullReload=true. I don't think that the case of fullReload=false has been tested much, so it is possible that there could be some strange bugs like in 3.2.x. It looks like the best way to fix this (for the default fullReload=true case) would be to add another hook to the API (e.g. copyContext(Context old, Context new)). This way, SimpleSessionStore could move the old sessions into the new Context before they get destroyed. Comments? - Original Message - From: Hugh J. L. [EMAIL PROTECTED] To: Tomcat Developers List [EMAIL PROTECTED] Sent: Monday, August 12, 2002 5:50 AM Subject: Question about Session in Tomcat 3.3 -- continued... I changed switch fullReload in ReloadInterceptor from true to false, and sessions are maintained through context reloading. (Of course, because the old context remains.) Is there any disadvantage if I set this way? Anyway fullReload=true is default setting. Thanks. Hugh __ Do You Yahoo!? HotJobs - Search Thousands of New Jobs http://www.hotjobs.com -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED] -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]