it really depends on what you consider a "reasonable" while. two hours? six
hours? ten hours? set your session timeout to that period and you wont have
a problem - configure your container to swap idle session to disk.

if you have pages in your app that you consider reasonable to abandon for a
while then the only requirement is to have bookmarkable links on those
pages. however, the backbutton still wont work.

-igor


On 6/18/07, Pieter Cogghe <[EMAIL PROTECTED]> wrote:

Hi,

As a result of how wicket stores pages in the session, links and pages do
expire quite often. I read a lot about it in the mailinglist archive, but
I'm still unsure how to handle it. It just seems very weird to run in to the
"page expired" message all the time. It's such a bad user experience: you
got to some page by some actions in the browser. For some time you leave the
browser for what it is, doing something else. You get back to your browser,
everything seems fine. You click a link and "BAM": you get directed to the
home page, completely loosing track from where you was.

Solutions I found:

- only use bookmarkable links, stateless pages -> can't use a lot of the
wicket-goodness, no stateless forms in 1.2 (?)
- keep pages alive with an ajax ping (doesn't help for the back button)

When do you use stateless pages and when statefull pages? Let's say I've
got this site structure:

mysite/login
mysite/home
mysite/songs/... (search, view, edit, add songs)
mysite/books/... (search, view, edit, add books)

Every action requires the user to be logged in!

Consider the following scenario's:

1
---
User Frederick logs in, searches the book "Snales and other monsters" and
views the details for that book. He gets distracted by the pineapple at his
desk for quite a while. He gets his attention back to the screen and clicks
to edit the book "Snales and other monsters" he was viewing before. He gets
redirected to the login page because the session has expired. He logs in and
gets automatically redirected to the edit form for the book "Snales and
other monsters".

2 (nearly the same, but with a form)
---
User Sarah logs in, searches a song "Anton aus Tirol" and starts editing
the song data, but doesn't submit the data. She gets away from her desk and
when she returns everyting seems fine to her. She continues editing the data
of "Anton aus Tirol" and submits. Her session has expired, so she gets
redirected to the login page. She logs in again and the data she wanted to
submit get submitted by the application. Sarah is shown the new data of
"Anton aus Tirol", which she submitted.

I guess the behaviour I want to achieve is only possible by using
stateless pages and bookmarkable links. Redirecting to the login page is no
problem ( setPageExpiredErrorPage*)*. How do I redirect users to the page
they left, after they logged in again and secondly how do I preserve
submitted data and submit it after the user logged in again?

thanks a lot,

Pieter

--
Pieter Cogghe
Ganzendries 186
9000 Gent
0487 10 14 21
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to