struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dave Newton <newton.d...@yahoo.com>
Subject Re: Struts2 sesionExpired page
Date Thu, 07 Feb 2008 13:01:26 GMT
In addition to the other suggestions posted you can also call the request's
isValidSessionId() method (or something like that).

Dave

--- "jignesh.patel" <jigneshd@aspl.in> wrote:

> 
> Hi,
>     I am having struts2 application with hibernate + mysql.I want to create
> web app session Expired page,but i am not able to detect weather my
> application session expired or not.
> 
> I have given session time out to 1 min also but it still displays active
> session.
> <session-config>
> 	<session-timeout>1</session-timeout>
> </session-config>
> 
> My SessionChecking interceptor looks like:-
> 
> public class SessionExpired  implements Interceptor {
>     public void destroy() {
> 	LOG.info("..............destroy");
>     }
> 
>     public void init() {
> 	LOG.info("..............init");
> 	}
> 	
>     public String intercept(ActionInvocation actionInvocation) throws
> Exception {
> 	Map session = actionInvocation.getInvocationContext().getSession();
> 	if(session == null) {
> 	     LOG.info("..............interce if");
> 	}
> 	else {
> 	    LOG.info("..............interce else");
> 	}
> 	return actionInvocation.invoke();
>     }
> }
> 
> After 1..2...3...5 min it still logging ("..............interce else").
> 
> Do anyone know how can i detect my application session time out or not ?
> 
> Thanks & regards
> jignesh
> -- 
> View this message in context:
> http://www.nabble.com/Struts2-sesionExpired-page-tp15328299p15328299.html
> Sent from the Struts - User mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message