struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nuwan Chandrasoma <>
Subject RE: Session Timeout
Date Wed, 30 Aug 2006 07:44:27 GMT
  I think a new session is created if you invoke an action mapping. this code will not work.
what you have to do is, add some attribute to the session.. and check if that attribute is
on the session. if not you can redirect to your session timeout page.
  Correct me if i am worng in here.

John De Lello <> wrote:
  The mandate is no JS. I'd prefer to not use a filter either for this. I was
just wondering why I was getting a valid session when the session was indeed

-----Original Message-----
From: faisal abdallah [] 
Sent: Tuesday, August 29, 2006 2:30 PM
To: Struts Developers List;
Subject: RE: Session Timeout 

This can be done easily with javascript inside the main layout
email me on and I will send you the code

-----Original Message-----
From: John De Lello [] 
Sent: Tuesday, August 29, 2006 11:15 AM
Subject: Session Timeout

Hey Everyone,

I am trying to use a custom session timeout JSP. To do this, I extended
"RequestProcessor" and overrode "processPreprocess" and added the following

HttpSession sess = req.getSession(false);

if(sess == null){
// even when the session IS timed out, I never get here.
String uri = "/myapp/sessiontimeout.jsp";
doForward(uri, req, resp);
}catch(Exception ex){}

return false;

The problem is, even when I know the session was expired, I never get a null
session. Am I missing something?


To unsubscribe, e-mail:
For additional commands, e-mail:

Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls.  Great rates starting at 1ยข/min.
  • Unnamed multipart/alternative (inline, 8-Bit, 0 bytes)
View raw message