wicket-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Grigorov <mgrigo...@apache.org>
Subject Re: Exception when Session expired
Date Tue, 12 Jun 2012 18:50:27 GMT
Hi,

On Mon, Jun 11, 2012 at 6:01 PM, sylvain
<sylvain.coste@interview-efm.com> wrote:
> Hi,
>
> I miragte in wicket 1.5 and I change the run timeException by this code
>
>                getRequestCycleListeners().add(new CommonRequestCycleListener()
{
>                        @Override
>                        public void onExceptionRequestHandlerResolved(RequestCycle
cycle,
> IRequestHandler handler, Exception exception) {
>                                // TODO Auto-generated method stub
>                                super.onExceptionRequestHandlerResolved(cycle,
handler, exception);
>                        }
>
>                        @Override
>                        public IRequestHandler onException(RequestCycle cycle,
Exception e) {
>                                Page page = new ErrorPage(e);
>                                try {
>                                        .....
>
>                                        if (e instanceof PageExpiredException)
{
>                                                Page expirationPage
= getExpirationPage();

Here 'expirationPage' is ignored.
Maybe it should be 'page = getExpirationPage()'

>                                        }
>                                } catch (QuestionnaireOrFormulaireNotFoundException
t) {
>                                        page = new QuestionnaireOrFormulaireNotFoundPage();
>                                } catch (Throwable t) {
>                                        page = new ErrorFormulairePage(t,
null);
>                                }
>                                return new RenderPageRequestHandler(new
PageProvider(page));
>                        }
>                });
>        }
>
> it's ok for a lot of error except for the expiration session.
>
> In wicket 1.4, when my session expired, i had a PageExpiredException but in
> wicket 1.5, don't it.
>
> Have you an idea why?
> How i can catch the exception of the expiration session?
>
> Thanks in advance
>
> Sylvain
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/Exception-when-Session-expired-tp4649854.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>



-- 
Martin Grigorov
jWeekend
Training, Consulting, Development
http://jWeekend.com
Mime
View raw message