RestartResponseException will render the page. since you invalidate
the session *after* rendering the page (session is invalidated at the
end of the request) that means any stateful urls constructed while
rendering the page will no longer be accessible
what you want to do is someting like this instead of restartresponseexception:
requestcycle.get().setrequesttarget(new irequesttarget() { respond(rc)
{ rc.sendredirect(rc.urlfor(sessionexpirtypage.class)); }
this will force a redirect before rendering the page
-igor
On Wed, Jun 2, 2010 at 2:58 PM, kugaprakash <[email protected]> wrote:
>
> Hi,
>
> Thanks much and appreciate your response.
>
> Yes, like I mentioned in the code snippet above, in the
> WebRequestCycleRequestProcesser.respond(), I override this method and
> handle the page expiration exception in the following way:
>
> if(e instanceof PageExpiredException || e instanceof
> HackAttackException){
>
> Session.get().invalidate();
>
> throw new
> RestartResponseException(SessionExpiryPage.class);
>
> }
>
>
>
> Which I believe will result in a bookmarkable page request target.
>
>
>
> Do you mean to say that I should not invalidate the session at above
> line, rather invalidate it in the SessionExpiryPage.onAfterRender()
>
>
>
> If the above is not what it is, can you please let me know with a little
> code sample?
>
> Thanks
>
> Kuga
>
> ________________________________
>
> From: Igor Vaynberg-2 [via Apache Wicket]
> [mailto:[email protected]]
> Sent: Wednesday, June 02, 2010 2:30 PM
> To: Kugaprakash Visagamani
> Subject: Re: Problem with Crypted URL
>
>
>
> maybe because you are invalidating the session, which happens after
> the page is rendered. i would instead invalidate the session and
> reditect to a bookmarkable url that points to the sessionexpiry page
>
> -igor
>
> On Wed, Jun 2, 2010 at 12:03 PM, kugaprakash <[hidden email]> wrote:
>
>
>>
>> Can anybody help me with this question?
>> --
>> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Problem-with-Crypted-URL-tp18
> 75435p2240647.html
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
>
>
> ________________________________
>
> View message @
> http://apache-wicket.1842946.n4.nabble.com/Problem-with-Crypted-URL-tp18
> 75435p2240861.html
> To unsubscribe from Re: Problem with Crypted URL, click here
> <http://apache-wicket.1842946.n4.nabble.com/subscriptions/Unsubscribe.jt
> p?code=a3Zpc2FnYW1hbmlAaW5mb2Jsb3guY29tfDIyNDA2NDd8NTcwMDE4MzI5> .
>
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Problem-with-Crypted-URL-tp1875435p2240905.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]