You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Erwan Tanajaya <r_...@yahoo.com.INVALID> on 2017/05/18 08:12:11 UTC

Wicket page expired if push button to open new page

hi all,
I have problem always get Page Expired error(event i set my session expired time to 8 hour), it happen if i open a page that had a datatable with have hundred of row.If i click a button that had a setResponsePage to a new page when the page is still loading and do something in the new opened page(push a button for example) it will cause Page Expired.
can anybody help me to solve this problem ?
i using :wicket 7.3tomcat 8.5java 8

Best Regards,Erwan

Re: Wicket page expired if push button to open new page

Posted by Erwan Tanajaya <r_...@yahoo.com.INVALID>.
Hi Maxim,
Thank you for your answer,
The user don't want a paging, how to block the page navigation until data fully available ?

Best Regards,Erwan Tanajaya

On Thursday, May 18, 2017, 3:16:21 PM GMT+7, Maxim Solodovnik <so...@gmail.com> wrote:Maybe it worth to add paging and limit displayed rows to some reasonable count?
Or block page navigations until data will be fully available?

On Thu, May 18, 2017 at 3:12 PM, Erwan Tanajaya <r_...@yahoo.com.invalid> wrote:
> hi all,
> I have problem always get Page Expired error(event i set my session expired time to 8 hour), it happen if i open a page that had a datatable with have hundred of row.If i click a button that had a setResponsePage to a new page when the page is still loading and do something in the new opened page(push a button for example) it will cause Page Expired.
> can anybody help me to solve this problem ?
> i using :wicket 7.3tomcat 8.5java 8
>
> Best Regards,Erwan



-- 
WBR
Maxim aka solomax

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org

Re: Wicket page expired if push button to open new page

Posted by Maxim Solodovnik <so...@gmail.com>.
Maybe it worth to add paging and limit displayed rows to some reasonable count?
Or block page navigations until data will be fully available?

On Thu, May 18, 2017 at 3:12 PM, Erwan Tanajaya <r_...@yahoo.com.invalid> wrote:
> hi all,
> I have problem always get Page Expired error(event i set my session expired time to 8 hour), it happen if i open a page that had a datatable with have hundred of row.If i click a button that had a setResponsePage to a new page when the page is still loading and do something in the new opened page(push a button for example) it will cause Page Expired.
> can anybody help me to solve this problem ?
> i using :wicket 7.3tomcat 8.5java 8
>
> Best Regards,Erwan



-- 
WBR
Maxim aka solomax

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket page expired if push button to open new page

Posted by Erwan Tanajaya <r_...@yahoo.com.INVALID>.
Hi Martin, 
Thank you for your answer

How can i know if the page has not been saved ?There are no stacktrace in my log saying anything when the exception occurred.
Best Regards,
Erwan
PS: Sorry for bad formatted email i don't know why(and English :p ), using yahoo mail

On Thursday, May 18, 2017, 3:31:43 PM GMT+7, Martin Grigorov <mg...@apache.org> wrote:Hi,

See PageExpiredException javadoc.
The exception is not thrown only when the session is expired.
Most probably the page has not be saved at all.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Thu, May 18, 2017 at 10:12 AM, Erwan Tanajaya <r_...@yahoo.com.invalid>
wrote:

> hi all,
> I have problem always get Page Expired error(event i set my session
> expired time to 8 hour), it happen if i open a page that had a datatable
> with have hundred of row.If i click a button that had a setResponsePage to
> a new page when the page is still loading and do something in the new
> opened page(push a button for example) it will cause Page Expired.
> can anybody help me to solve this problem ?
> i using :wicket 7.3tomcat 8.5java 8
>
> Best Regards,Erwan
>

Re: Wicket page expired if push button to open new page

Posted by Erwan Tanajaya <r_...@yahoo.com.INVALID>.
Thank you Maxim,
I will try to implement your example as workaround
Best Regards,Erwan

PS: Sorry for bad formatted email i don't know why(and English :p ), using yahoo mail

On Thursday, May 18, 2017, 3:39:53 PM GMT+7, Maxim Solodovnik <so...@gmail.com> wrote:In case Ajax is available you can start with button disabled by default
Then add AbstractDefaultAjaxBehavior to the page and trigger it on dom ready:

@Override
public void renderHead(IHeaderResponse response) {
    response.render(OnDomReadyHeaderItem.forScript(myBehavior.getCallbackScript()));
}

and enable your buttons in myBehavior response

On Thu, May 18, 2017 at 3:30 PM, Martin Grigorov <mg...@apache.org> wrote:
> Hi,
>
> See PageExpiredException javadoc.
> The exception is not thrown only when the session is expired.
> Most probably the page has not be saved at all.
>
> Martin Grigorov
> Wicket Training and Consulting
> https://twitter.com/mtgrigorov
>
> On Thu, May 18, 2017 at 10:12 AM, Erwan Tanajaya <r_...@yahoo.com.invalid>
> wrote:
>
>> hi all,
>> I have problem always get Page Expired error(event i set my session
>> expired time to 8 hour), it happen if i open a page that had a datatable
>> with have hundred of row.If i click a button that had a setResponsePage to
>> a new page when the page is still loading and do something in the new
>> opened page(push a button for example) it will cause Page Expired.
>> can anybody help me to solve this problem ?
>> i using :wicket 7.3tomcat 8.5java 8
>>
>> Best Regards,Erwan
>>



-- 
WBR
Maxim aka solomax

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket page expired if push button to open new page

Posted by Maxim Solodovnik <so...@gmail.com>.
In case Ajax is available you can start with button disabled by default
Then add AbstractDefaultAjaxBehavior to the page and trigger it on dom ready:

@Override
public void renderHead(IHeaderResponse response) {
     response.render(OnDomReadyHeaderItem.forScript(myBehavior.getCallbackScript()));
}

and enable your buttons in myBehavior response

On Thu, May 18, 2017 at 3:30 PM, Martin Grigorov <mg...@apache.org> wrote:
> Hi,
>
> See PageExpiredException javadoc.
> The exception is not thrown only when the session is expired.
> Most probably the page has not be saved at all.
>
> Martin Grigorov
> Wicket Training and Consulting
> https://twitter.com/mtgrigorov
>
> On Thu, May 18, 2017 at 10:12 AM, Erwan Tanajaya <r_...@yahoo.com.invalid>
> wrote:
>
>> hi all,
>> I have problem always get Page Expired error(event i set my session
>> expired time to 8 hour), it happen if i open a page that had a datatable
>> with have hundred of row.If i click a button that had a setResponsePage to
>> a new page when the page is still loading and do something in the new
>> opened page(push a button for example) it will cause Page Expired.
>> can anybody help me to solve this problem ?
>> i using :wicket 7.3tomcat 8.5java 8
>>
>> Best Regards,Erwan
>>



-- 
WBR
Maxim aka solomax

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Wicket page expired if push button to open new page

Posted by Martin Grigorov <mg...@apache.org>.
Hi,

See PageExpiredException javadoc.
The exception is not thrown only when the session is expired.
Most probably the page has not be saved at all.

Martin Grigorov
Wicket Training and Consulting
https://twitter.com/mtgrigorov

On Thu, May 18, 2017 at 10:12 AM, Erwan Tanajaya <r_...@yahoo.com.invalid>
wrote:

> hi all,
> I have problem always get Page Expired error(event i set my session
> expired time to 8 hour), it happen if i open a page that had a datatable
> with have hundred of row.If i click a button that had a setResponsePage to
> a new page when the page is still loading and do something in the new
> opened page(push a button for example) it will cause Page Expired.
> can anybody help me to solve this problem ?
> i using :wicket 7.3tomcat 8.5java 8
>
> Best Regards,Erwan
>